Micron Document
<!DOCTYPE html>
<html class="client-nojs vector-feature-night-mode-disabled vector-feature-language-in-header-enabled vector-feature-language-in-main-page-header-disabled vector-feature-page-tools-pinned-disabled vector-feature-toc-pinned-clientpref-1 vector-feature-main-menu-pinned-disabled vector-feature-limited-width-clientpref-1 vector-feature-limited-width-content-enabled vector-feature-custom-font-size-clientpref-1 vector-feature-appearance-pinned-clientpref-1 vector-sticky-header-enabled" lang="en" dir="ltr"><head>
<meta charset="UTF-8">
<title>Raku (programming language)</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="canonical" href="https://en.wikipedia.org/wiki/Raku_(programming_language)"> <link href="./mw/ext.cite.styles.css" rel="stylesheet" type="text/css">
<link href="./mw/ext.pygments.css" rel="stylesheet" type="text/css">
<link href="./mw/skins.vector.icons.css" rel="stylesheet" type="text/css">
<link href="./mw/skins.vector.search.codex.styles.css" rel="stylesheet" type="text/css">
<link href="./mw/skins.vector.styles.css" rel="stylesheet" type="text/css">
<link href="./mw/user.styles.css" rel="stylesheet" type="text/css">
<meta name="ResourceLoaderDynamicStyles" content="">
<link rel="stylesheet" type="text/css" href="./mw/site.styles.css">
<link rel="stylesheet" type="text/css" href="./mw/noscript.css">
<link rel="stylesheet" type="text/css" href="./footer.css">
<link rel="stylesheet" type="text/css" href="./vector-2022.css">
</head>
<body class="skin--responsive skin-vector skin-vector-search-vue mediawiki ltr sitedir-ltr mw-hide-empty-elt ns-0 ns-subject page-Raku_programming_language rootpage-Raku_programming_language skin-vector-2022 action-view">
<div class="mw-page-container">
<div class="mw-page-container-inner">
<div class="mw-content-container">
<main id="content" class="mw-body">
<header class="mw-body-header vector-page-titlebar">
<h1 id="firstHeading" class="firstHeading mw-first-heading">
<span id="openzim-page-title" class="mw-page-title-main"><span class="mw-page-title-main">Raku (programming language)</span></span>
</h1>
</header>
<a id="top"></a>
<div id="bodyContent" class="vector-body ve-init-mw-desktopArticleTarget-targetContainer" aria-labelledby="firstHeading" data-mw-ve-target-container="">
<div id="mw-content-text" class="mw-body-content mw-content-ltr" lang="en" dir="ltr"><div class="mw-content-ltr mw-parser-output" lang="en" dir="ltr">
<p class="mw-empty-elt">
</p>
<style data-mw-deduplicate="TemplateStyles:r1295905060">
/* start https://en.wikipedia.org/ */


.mw-parser-output .infobox-subbox{padding:0;border:none;margin:-3px;width:auto;min-width:100%;font-size:100%;clear:none;float:none;background-color:transparent}.mw-parser-output .infobox-3cols-child{margin:auto}.mw-parser-output .infobox .navbar{font-size:100%}@media screen{html.skin-theme-clientpref-night .mw-parser-output .infobox-full-data:not(.notheme)>div:not(.notheme)[style]{background:#1f1f23!important;color:#f8f9fa}}@media screen and (prefers-color-scheme:dark){html.skin-theme-clientpref-os .mw-parser-output .infobox-full-data:not(.notheme)>div:not(.notheme)[style]{background:#1f1f23!important;color:#f8f9fa}}@media(min-width:640px){body.skin--responsive .mw-parser-output .infobox-table{display:table!important}body.skin--responsive .mw-parser-output .infobox-table>caption{display:table-caption!important}body.skin--responsive .mw-parser-output .infobox-table>tbody{display:table-row-group}body.skin--responsive .mw-parser-output .infobox-table th,body.skin--responsive .mw-parser-output .infobox-table td{padding-left:inherit;padding-right:inherit}}


/* end https://en.wikipedia.org/ */
</style><table class="infobox vevent"><tbody><tr><th colspan="2" class="infobox-above" style="background-color:#e0e0e0;">Raku</th></tr><tr><td colspan="2" class="infobox-image"><span typeof="mw:File"></span><div class="infobox-caption">Camelia, the Raku mascot<sup id="cite_ref-camelia_1-0" class="reference"><a href="#cite_note-camelia-1"><span class="cite-bracket">[</span>1<span class="cite-bracket">]</span></a></sup></div></td></tr><tr><th scope="row" class="infobox-label"><a href="Programming_paradigm" title="Programming paradigm">Paradigm</a></th><td class="infobox-data"><a href="Multi-paradigm" class="mw-redirect" title="Multi-paradigm">Multi-paradigm</a></td></tr><tr><th scope="row" class="infobox-label">Family</th><td class="infobox-data"><a href="Perl" title="Perl">Perl</a></td></tr><tr><th scope="row" class="infobox-label"><a href="Software_design" title="Software design">Designed&nbsp;by</a></th><td class="infobox-data"><a href="Larry_Wall" title="Larry Wall">Larry Wall</a></td></tr><tr><th scope="row" class="infobox-label"><a href="Software_developer" class="mw-redirect" title="Software developer">Developer</a></th><td class="infobox-data organiser">Raku community</td></tr><tr><th scope="row" class="infobox-label">First&nbsp;appeared</th><td class="infobox-data">25&nbsp;December 2015<span style="display:none">&nbsp;(<span class="bday dtstart published updated">2015-12-25</span>)</span></td></tr><tr><td colspan="2" class="infobox-full-data"></td></tr><tr><th scope="row" class="infobox-label" style="white-space: nowrap;"><a href="Software_release_life_cycle" title="Software release life cycle">Stable release</a></th><td class="infobox-data"><div style="margin:0px;">6.d 'Diwali'<sup id="cite_ref-2" class="reference"><a href="#cite_note-2"><span class="cite-bracket">[</span>2<span class="cite-bracket">]</span></a></sup>
/ 24&nbsp;October 2020<span style="display:none">&nbsp;(<span class="bday dtstart published updated">2020-10-24</span>)</span></div></td></tr><tr style="display:none"><td colspan="2">
</td></tr><tr><th scope="row" class="infobox-label"><a href="Type_system" title="Type system">Typing discipline</a></th><td class="infobox-data"><a href="Dynamic_typing" class="mw-redirect" title="Dynamic typing">Dynamic</a>, <a href="Gradual_typing" title="Gradual typing">gradual</a></td></tr><tr><th scope="row" class="infobox-label"><a href="Operating_system" title="Operating system">OS</a></th><td class="infobox-data"><a href="Cross-platform" class="mw-redirect" title="Cross-platform">Cross-platform</a></td></tr><tr><th scope="row" class="infobox-label"><a href="Software_license" title="Software license">License</a></th><td class="infobox-data"><a href="GNU_General_Public_License" title="GNU General Public License">GNU General Public</a> or <a href="Artistic_License" title="Artistic License">Artistic 2</a></td></tr><tr><th scope="row" class="infobox-label"><a href="Filename_extension" title="Filename extension">Filename extensions</a></th><td class="infobox-data">.raku, .rakumod, .rakudoc, .rakutest, .nqp <sup id="cite_ref-3" class="reference"><a href="#cite_note-3"><span class="cite-bracket">[</span>3<span class="cite-bracket">]</span></a></sup></td></tr><tr><th scope="row" class="infobox-label">Website</th><td class="infobox-data"><span class="url"><a rel="nofollow" class="external text" href="https://raku.org/">raku<wbr>.org</a></span></td></tr><tr><th colspan="2" class="infobox-header" style="background-color: #EEEEEE;">Major <a href="Programming_language_implementation" title="Programming language implementation">implementations</a></th></tr><tr><td colspan="2" class="infobox-full-data"><a href="Rakudo" title="Rakudo">Rakudo</a></td></tr><tr><th colspan="2" class="infobox-header" style="background-color: #EEEEEE;">Influenced by</th></tr><tr><td colspan="2" class="infobox-full-data"><a href="Perl" title="Perl">Perl</a>, <a href="Ruby_(programming_language)" title="Ruby (programming language)">Ruby</a>, <a href="Smalltalk" title="Smalltalk">Smalltalk</a>, <a href="Haskell" title="Haskell">Haskell</a>,<sup id="cite_ref-4" class="reference"><a href="#cite_note-4"><span class="cite-bracket">[</span>4<span class="cite-bracket">]</span></a></sup> <a href="JavaScript" title="JavaScript">JavaScript</a></td></tr><tr><th colspan="2" class="infobox-header" style="background-color: #EEEEEE;">Influenced</th></tr><tr><td colspan="2" class="infobox-full-data"><a href="Perl" title="Perl">Perl</a>,<sup id="cite_ref-Tang2010_5-0" class="reference"><a href="#cite_note-Tang2010-5"><span class="cite-bracket">[</span>5<span class="cite-bracket">]</span></a></sup> <a href="Haskell" title="Haskell">Haskell</a>,<sup id="cite_ref-Tang2010_5-1" class="reference"><a href="#cite_note-Tang2010-5"><span class="cite-bracket">[</span>5<span class="cite-bracket">]</span></a></sup> AntLang</td></tr></tbody></table>
<p><b>Raku</b> is a member of the <a href="Perl" title="Perl">Perl</a> family of <a href="Programming_language" title="Programming language">programming languages</a>.<sup id="cite_ref-6" class="reference"><a href="#cite_note-6"><span class="cite-bracket">[</span>6<span class="cite-bracket">]</span></a></sup> Formerly named <b>Perl 6</b>, it was renamed in October 2019.<sup id="cite_ref-renamed_7-0" class="reference"><a href="#cite_note-renamed-7"><span class="cite-bracket">[</span>7<span class="cite-bracket">]</span></a></sup><sup id="cite_ref-8" class="reference"><a href="#cite_note-8"><span class="cite-bracket">[</span>8<span class="cite-bracket">]</span></a></sup> Raku introduces elements of many modern and historical languages. Compatibility with Perl was not a goal, though a <a href="Compatibility_mode" title="Compatibility mode">compatibility mode</a> is part of the specification. The design process for Raku began in 2000.
</p>
<meta property="mw:PageProp/toc">
<div class="mw-heading mw-heading2"><h2 id="History">History</h2></div>
<style data-mw-deduplicate="TemplateStyles:r1244412712">
/* start https://en.wikipedia.org/ */


.mw-parser-output .templatequote{overflow:hidden;margin:1em 0;padding:0 32px}.mw-parser-output .templatequotecite{line-height:1.5em;text-align:left;margin-top:0}@media(min-width:500px){.mw-parser-output .templatequotecite{padding-left:1.6em}}


/* end https://en.wikipedia.org/ */
</style><blockquote class="templatequote"><p>In Perl 6, we decided it would be better to fix the language than fix the user.</p></blockquote><div class="templatequotecite"><p style="display: inline; padding-left: 2.3em;">— Larry Wall<sup id="cite_ref-9" class="reference"><a href="#cite_note-9"><span class="cite-bracket">[</span>9<span class="cite-bracket">]</span></a></sup></p></div>
<p>The Raku design process was first announced on 19 July 2000, on the fourth day of that year's <a href="O'Reilly_Open_Source_Convention" title="O'Reilly Open Source Convention">Perl Conference</a>,<sup id="cite_ref-10" class="reference"><a href="#cite_note-10"><span class="cite-bracket">[</span>10<span class="cite-bracket">]</span></a></sup> by <a href="Larry_Wall" title="Larry Wall">Larry Wall</a> in his <i><a href="Perl#Community" title="Perl">State of the Onion</a> 2000</i> talk.<sup id="cite_ref-11" class="reference"><a href="#cite_note-11"><span class="cite-bracket">[</span>11<span class="cite-bracket">]</span></a></sup> At that time, the primary goals were to remove "historical warts" from the language; "easy things should stay easy, hard things should get easier, and impossible things should get hard"; and a general cleanup of the internal design and <a href="Application_programming_interface" class="mw-redirect" title="Application programming interface">application programming interfaces</a> (APIs). The process began with a series of <a href="Request_for_Comments" title="Request for Comments">Request for Comments</a> (RFCs). This process was open to all contributors, and left no aspect of the language closed to change.<sup id="cite_ref-12" class="reference"><a href="#cite_note-12"><span class="cite-bracket">[</span>12<span class="cite-bracket">]</span></a></sup>
</p><p>Once the RFC process was complete, Wall reviewed and classified each of the 361 requests received. He then began the process of writing several "Apocalypses", using <a href="https://en.wiktionary.org/wiki/apocalypsis#English" class="extiw external" title="wikt:apocalypsis">the original meaning of the term</a>, "revealing".<sup id="cite_ref-apoc1_13-0" class="reference"><a href="#cite_note-apoc1-13"><span class="cite-bracket">[</span>13<span class="cite-bracket">]</span></a></sup> While the original goal was to write one Apocalypse for each chapter of <i><a href="Programming_Perl" title="Programming Perl">Programming Perl</a></i>, it became obvious that, as each Apocalypse was written, previous Apocalypses were being invalidated by later changes. For this reason, a set of Synopses was published, each one relating the contents of an Apocalypse, but with any subsequent changes reflected in updates. Today, the Raku specification is managed through the "roast" testing suite,<sup id="cite_ref-14" class="reference"><a href="#cite_note-14"><span class="cite-bracket">[</span>14<span class="cite-bracket">]</span></a></sup> while the Synopses are kept as a historical reference.<sup id="cite_ref-syn_15-0" class="reference"><a href="#cite_note-syn-15"><span class="cite-bracket">[</span>15<span class="cite-bracket">]</span></a></sup>
</p><p>There is also a series of <a href="https://en.wiktionary.org/wiki/exegesis#English" class="extiw external" title="wikt:exegesis">Exegeses</a> written by <a href="Damian_Conway" title="Damian Conway">Damian Conway</a> that explain the content of each Apocalypse in terms of practical usage. Each Exegesis consists of code examples along with a discussion of the usage and implications of the examples.<sup id="cite_ref-exegeses_16-0" class="reference"><a href="#cite_note-exegeses-16"><span class="cite-bracket">[</span>16<span class="cite-bracket">]</span></a></sup>
</p><p>There are three primary methods of communication used in the development of Raku today. The first is the Raku <a href="Internet_Relay_Chat" class="mw-redirect" title="Internet Relay Chat">Internet Relay Chat</a> (IRC) channel on <a href="Libera_Chat" title="Libera Chat">Libera Chat</a>. The second is a set of <a href="Mailing_list" title="Mailing list">mailing lists</a>.<sup id="cite_ref-lists_17-0" class="reference"><a href="#cite_note-lists-17"><span class="cite-bracket">[</span>17<span class="cite-bracket">]</span></a></sup> The third is the <a href="Git_(software)" class="mw-redirect" title="Git (software)">Git</a> <a href="Source_code_repository" class="mw-redirect" title="Source code repository">source code repository</a> hosted at <a href="GitHub" title="GitHub">GitHub</a>.<sup id="cite_ref-18" class="reference"><a href="#cite_note-18"><span class="cite-bracket">[</span>18<span class="cite-bracket">]</span></a></sup>
</p>
<div class="mw-heading mw-heading3"><h3 id="Initial_goals_and_implications">Initial goals and implications</h3></div>
<p>The major goal Wall suggested in his initial speech was the removal of historical warts. These included the confusion surrounding <a href="Sigil_(computer_programming)" title="Sigil (computer programming)">sigil</a> usage for containers, the ambiguity between the <code>select</code> functions, and the syntactic impact of bareword <a href="Filehandle" class="mw-redirect" title="Filehandle">filehandles</a>. There were many other problems that Perl programmers had discussed fixing for years, and these were explicitly addressed by Wall in his speech.
</p><p>An implication of these goals was that Perl 6 would not have <a href="Backward_compatibility" title="Backward compatibility">backward compatibility</a> with the existing Perl codebase. This meant that some code which was correctly interpreted by a Perl 5 compiler would not be accepted by a Perl 6 compiler. Since backward compatibility is a common goal when enhancing software, the breaking changes in Perl 6 had to be stated explicitly. The distinction between Perl 5 and Perl 6 became so large that eventually Perl 6 was renamed Raku.
</p>
<div class="mw-heading mw-heading3"><h3 id="Mascot">Mascot</h3></div>

<p>The language's <a href="Mascot" title="Mascot">mascot</a> is "Camelia, the Raku bug".<sup id="cite_ref-camelia_1-1" class="reference"><a href="#cite_note-camelia-1"><span class="cite-bracket">[</span>1<span class="cite-bracket">]</span></a></sup>
Her name is a nod to the camel mascot associated with <a href="Perl" title="Perl">Perl</a>, and her form, in the pun-loving tradition of the Perl community, is a play on "<a href="Software_bug" title="Software bug">software bug</a>". Spiral designs embedded in her butterfly-like wings resemble the characters "P6", the favored nickname for Perl 6, and off-center eye placement is an intentional pun on "Wall-eyed".<sup id="cite_ref-camelia-eyes_19-0" class="reference"><a href="#cite_note-camelia-eyes-19"><span class="cite-bracket">[</span>19<span class="cite-bracket">]</span></a></sup>
</p><p>One of the goals behind the lively and colorful design of the logo was to discourage misogyny in the community and for it to be an opportunity for those of "masculine persuasion" to show their sensitive side.<sup id="cite_ref-camelia-purpose_20-0" class="reference"><a href="#cite_note-camelia-purpose-20"><span class="cite-bracket">[</span>20<span class="cite-bracket">]</span></a></sup>
</p>
<div class="mw-heading mw-heading2"><h2 id="Implementations">Implementations</h2></div>
<p>As of 2017, only the <a href="Rakudo" title="Rakudo">Rakudo</a> implementation is under active development. No implementation will be designated as the official Raku implementation; rather, "Raku is anything that passes the official test suite."<sup id="cite_ref-21" class="reference"><a href="#cite_note-21"><span class="cite-bracket">[</span>21<span class="cite-bracket">]</span></a></sup>
</p><p>Rakudo Perl 6<sup id="cite_ref-22" class="reference"><a href="#cite_note-22"><span class="cite-bracket">[</span>22<span class="cite-bracket">]</span></a></sup><sup id="cite_ref-23" class="reference"><a href="#cite_note-23"><span class="cite-bracket">[</span>23<span class="cite-bracket">]</span></a></sup> targets a number of virtual machines, such as <a href="MoarVM" title="MoarVM">MoarVM</a>, the <a href="Java_virtual_machine" title="Java virtual machine">Java Virtual Machine</a>, and <a href="JavaScript" title="JavaScript">JavaScript</a>. MoarVM is a <a href="Virtual_machine" title="Virtual machine">virtual machine</a> built especially for Rakudo<sup id="cite_ref-24" class="reference"><a href="#cite_note-24"><span class="cite-bracket">[</span>24<span class="cite-bracket">]</span></a></sup> and the NQP Compiler Toolchain.<sup id="cite_ref-25" class="reference"><a href="#cite_note-25"><span class="cite-bracket">[</span>25<span class="cite-bracket">]</span></a></sup> There is a layer between Raku and the virtual machines named Not Quite Perl 6 (NQP), which implements <a href="Raku_rules" title="Raku rules">Raku rules</a> for parsing Raku, and an <a href="Abstract_syntax_tree" title="Abstract syntax tree">abstract syntax tree</a> and backend-specific <a href="Code_generation_(compiler)" title="Code generation (compiler)">code generation</a>. Large portions of Rakudo are written in Raku, or in its subset NQP. Rakudo is not a completely <a href="Self-hosting_(compilers)" title="Self-hosting (compilers)">self-hosting implementation</a>, nor are there concrete plans at this point to make Rakudo a <a href="Bootstrapping_(compilers)" title="Bootstrapping (compilers)">bootstrapping compiler</a>.
</p>
<div class="mw-heading mw-heading3"><h3 id="Historical_implementations">Historical implementations</h3></div>
<p><a href="Pugs_(compiler)" title="Pugs (compiler)">Pugs</a> was an initial implementation of Perl 6 written in <a href="Haskell" title="Haskell">Haskell</a>, led by <a href="Audrey_Tang" title="Audrey Tang">Audrey Tang</a>. Pugs used to be the most advanced implementation of Perl 6, but since mid 2007, it is mostly dormant (with updates made only to track the current version of the <a href="Glasgow_Haskell_Compiler" title="Glasgow Haskell Compiler">Glasgow Haskell Compiler</a> (GHC)). As of November 2014, Pugs was not being maintained.<sup id="cite_ref-26" class="reference"><a href="#cite_note-26"><span class="cite-bracket">[</span>26<span class="cite-bracket">]</span></a></sup>
</p><p>In 2007, v6-MiniPerl6 ("mp6") and its reimplementation, v6-KindaPerl6 ("kp6") were written as a means to bootstrap the Perl-6.0.0 STD, using Perl 5. The STD is a full grammar for Perl 6 and is written in Perl 6. In theory, anything capable of parsing the STD and generating executable code is a suitable bootstrapping system for Perl 6. kp6 is currently compiled by mp6 and can work with multiple backends.<sup id="cite_ref-STD_27-0" class="reference"><a href="#cite_note-STD-27"><span class="cite-bracket">[</span>27<span class="cite-bracket">]</span></a></sup><sup id="cite_ref-28" class="reference"><a href="#cite_note-28"><span class="cite-bracket">[</span>28<span class="cite-bracket">]</span></a></sup> mp6 and kp6 are not full Perl 6 implementations and are designed only to implement the minimum featureset required to bootstrap a full Perl 6 compiler.
</p><p>Yapsi was a Perl 6 compiler and runtime written in Perl 6. As a result, it required an existing Perl 6 interpreter, such as one of the Rakudo Star releases, to run.<sup id="cite_ref-29" class="reference"><a href="#cite_note-29"><span class="cite-bracket">[</span>29<span class="cite-bracket">]</span></a></sup>
</p><p>Niecza, another major Perl 6 implementation effort, focused on optimization and efficient implementation research. It targets the <a href="Common_Language_Infrastructure" title="Common Language Infrastructure">Common Language Infrastructure</a>.<sup id="cite_ref-nieczareadme_30-0" class="reference"><a href="#cite_note-nieczareadme-30"><span class="cite-bracket">[</span>30<span class="cite-bracket">]</span></a></sup>
</p>
<div class="mw-heading mw-heading2"><h2 id="Module_system">Module system</h2></div>
<p>The Raku specification requests that <a href="Perl_module" title="Perl module">modules</a> be identified by name, version, and authority.<sup id="cite_ref-31" class="reference"><a href="#cite_note-31"><span class="cite-bracket">[</span>31<span class="cite-bracket">]</span></a></sup> It is possible to load only a specific version of a module, or even two modules of the same name that differ in version or authority. As a convenience, <a href="Aliasing_(computing)" title="Aliasing (computing)">aliasing</a> to a short name is provided.
</p><p><a href="CPAN" title="CPAN">CPAN</a>, the Perl module distribution system, does not yet handle Raku modules. Instead a prototype module system is in use.<sup id="cite_ref-32" class="reference"><a href="#cite_note-32"><span class="cite-bracket">[</span>32<span class="cite-bracket">]</span></a></sup>
</p>
<div class="mw-heading mw-heading2"><h2 id="Major_changes_from_Perl">Major changes from Perl</h2></div>
<p>Perl and Raku differ fundamentally, though in general the intent has been to "keep Raku Perl", so that Raku is clearly "a Perl programming language". Most of the changes are intended to normalize the language, to make it easier for novice and expert programmers alike to understand, and to make "easy things easier and hard things more possible".
</p>
<div class="mw-heading mw-heading3"><h3 id="A_specification">A specification</h3></div>
<p>A major non-technical difference between Perl and Raku is that Raku began as a specification.<sup id="cite_ref-syn01_33-0" class="reference"><a href="#cite_note-syn01-33"><span class="cite-bracket">[</span>33<span class="cite-bracket">]</span></a></sup> This means that Raku can be re-implemented if needed, and it also means that programmers do not have to read the <a href="Source_code" title="Source code">source code</a> for the ultimate authority on any given feature. In contrast, in Perl, the official documentation is not considered authoritative and only describes the behavior of the actual Perl interpreter informally. Any discrepancies found between the documentation and the implementation may lead to either being changed to reflect the other, a dynamic which drives the continuing development and refinement of the Perl releases.
</p>
<div class="mw-heading mw-heading3"><h3 id="A_type_system">A type system</h3></div>
<p>In Raku, the <a href="Dynamic_type" class="mw-redirect" title="Dynamic type">dynamic type system</a> of Perl has been augmented by the addition of <a href="Static_type" class="mw-redirect" title="Static type">static types</a>.<sup id="cite_ref-syn2_34-0" class="reference"><a href="#cite_note-syn2-34"><span class="cite-bracket">[</span>34<span class="cite-bracket">]</span></a></sup> For example:
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="k">my</span> <span class="nb">Int</span> <span class="nv">$i</span> = <span class="mi">0</span>;
<span class="k">my</span> <span class="nb">Rat</span> <span class="nv">$r</span> = <span class="mf">3.142</span>;
<span class="k">my</span> <span class="nb">Str</span> <span class="nv">$s</span> = <span class="s">"Hello, world"</span>;
</pre></div>
<p>However, static typing remains <a href="Type_system#Combining_static_and_dynamic_type_checking" title="Type system">optional</a>, so programmers can do most things without any explicit typing at all:
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="k">my</span> <span class="nv">$i</span> = <span class="s">"25"</span> + <span class="mi">10</span>; <span class="c1"># $i is 35</span>
</pre></div>
<p>Raku offers a <a href="Gradual_typing" title="Gradual typing">gradual typing</a> system, whereby the programmer may choose to use static typing, use dynamic typing, or mix the two.
</p>
<div class="mw-heading mw-heading3"><h3 id="Formal_subroutine_parameter_lists">Formal subroutine parameter lists</h3></div>
<p>Perl defines subroutines without <a href="Parameter_(computer_science)" class="mw-redirect" title="Parameter (computer science)">formal parameter</a> lists at all (though simple parameter counting and some type checking can be done using Perl's "prototypes"). Subroutine arguments passed in are aliased into the elements of the array <code>@_</code>. If the elements of <code>@_</code> are modified, the changes are reflected in the original data.
</p><p>Raku introduces true formal parameters to the language.<sup id="cite_ref-syn6_35-0" class="reference"><a href="#cite_note-syn6-35"><span class="cite-bracket">[</span>35<span class="cite-bracket">]</span></a></sup> In Raku, a subroutine declaration looks like this:
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="k">sub</span> <span class="n">do_something</span>(<span class="nb">Str</span> <span class="nv">$thing</span>, <span class="nb">Int</span> <span class="nv">$other</span>) {
...
}
</pre></div>
<p>As in Perl, the formal parameters (i.e., the variables in the parameter list) are aliases to the actual parameters (the values passed in), but by default, the aliases are <a href="Constant_(programming)" class="mw-redirect" title="Constant (programming)">constant</a> so they cannot be modified. They may be declared explicitly as read-write aliases for the original value or as copies using the <code>is rw</code> or <code>is copy</code> directives respectively should the programmer require them to be modified locally.
</p>
<div class="mw-heading mw-heading4"><h4 id="Parameter_passing_modes">Parameter passing modes</h4></div>
<p>Raku provides three basic modes of parameter passing: positional parameters, <a href="Named_parameter" title="Named parameter">named parameters</a>, and slurpy parameters.
</p><p>Positional parameters are the typical ordered list of parameters that most programming languages use. All parameters may also be passed by using their name in an unordered way. Named-only parameters (indicated by a <code>:</code> before the parameter name) can only be passed by specifying its name, i.e. it never captures a positional argument. Slurpy parameters (indicated by an <code>*</code> before the parameter name) are Raku's tool for creating <a href="Variadic_function" title="Variadic function">variadic functions</a>. A slurpy hash will capture remaining passed-by-name parameters, whereas a slurpy array will capture remaining passed-by-position parameters.
</p><p>Here is an example of the use of all three parameter-passing modes:
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="k">sub</span> <span class="n">somefunction</span>(<span class="nv">$a</span>, <span class="nv">$b</span>,&nbsp;:<span class="nv">$c</span>,&nbsp;:<span class="nv">$d</span>, *<span class="nv">@e</span>) {
...
}

<span class="n">somefunction</span>(<span class="mi">1</span>, <span class="mi">2</span>,&nbsp;:<span class="n">d</span>(<span class="mi">3</span>), <span class="mi">4</span>, <span class="mi">5</span>, <span class="mi">6</span>); <span class="c1"># $a=1, $b=2, $d=3, @e=(4,5,6)</span>
</pre></div>
<p>Positional parameters, such as those used above, are always required unless followed by <code>?</code> to indicate that they are optional. Named parameters are optional by default, but may be marked as required by adding <code>!</code> after the variable name. Slurpy parameters are <i>always</i> optional.
</p>
<div class="mw-heading mw-heading4"><h4 id="Blocks_and_closures">Blocks and closures</h4></div>
<p>Parameters can also be passed to arbitrary blocks, which act as <a href="Closure_(computer_science)" class="mw-redirect" title="Closure (computer science)">closures</a>. This is how, for example, <code>for</code> and <code>while</code> loop iterators are named. In the following example, a list is traversed, 3 elements at a time, and passed to the loop's block as the variables, <code>$a, $b, $c</code>.<sup id="cite_ref-syn04_36-0" class="reference"><a href="#cite_note-syn04-36"><span class="cite-bracket">[</span>36<span class="cite-bracket">]</span></a></sup>
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="k">for</span> <span class="nv">@list</span> -&gt; <span class="nv">$a</span>, <span class="nv">$b</span>, <span class="nv">$c</span> {
...
}
</pre></div>
<p>This is generally referred to as a "pointy sub" or "pointy block", and the arrow behaves almost exactly like the <code>sub</code> keyword, introducing an anonymous closure (or anonymous subroutine in Perl terminology).<sup id="cite_ref-syn6_35-1" class="reference"><a href="#cite_note-syn6-35"><span class="cite-bracket">[</span>35<span class="cite-bracket">]</span></a></sup>
</p>
<div class="mw-heading mw-heading3"><h3 id="Sigil_invariance">Sigil invariance</h3></div>
<p>In Perl, <a href="Sigil_(computer_programming)" title="Sigil (computer programming)"><i>sigils</i></a> – the punctuation characters that precede a variable name – change depending on how the variable is used:
</p>
<pre># Perl code
my <span style="color:red;">@</span>array = ('a', 'b', 'c');
my $element = <span style="color:red;">$</span>array[1]; # $element equals 'b',
my @extract = <span style="color:red;">@</span>array[1, 2]; # @extract equals ('b', 'c')
my $element = <span style="color:red;">@</span>array[1]; # 'b' comes with a warning (5.10 option)
</pre>
<p>In Raku, sigils are invariant, which means that they do not change based on whether it is the array or the array element that is needed:<sup id="cite_ref-syn2_34-1" class="reference"><a href="#cite_note-syn2-34"><span class="cite-bracket">[</span>34<span class="cite-bracket">]</span></a></sup>
</p>
<pre># Raku code
my <span style="color:red;">@</span>array = 'a', 'b', 'c';
my $element = <span style="color:red;">@</span>array[1]; # $element equals 'b'
my @extract = <span style="color:red;">@</span>array[1, 2]; # @extract equals ('b', 'c')
my @extract = <span style="color:red;">@</span>array[1]; # @extract equals ('b')
</pre>
<p>The variance in Perl is inspired by number agreement in English and many other natural languages:
</p>
<pre>"<b>This</b> apple." # $a CORRECT
"<b>These</b> apples." # @a CORRECT
"<b>This</b> third apple." # $a[3] CORRECT
"<b>These</b> third apple." # @a[3] WRONG
</pre>
<p>However, this conceptual mapping breaks down when using <a href="Reference_(computer_science)" title="Reference (computer science)">references</a>, since they may refer to data structures even though they are scalars. Thus, dealing with nested data structures may require an expression of both singular and plural form in a single term:
</p>
<div class="mw-highlight mw-highlight-lang-perl mw-content-ltr" dir="ltr"><pre><span class="c1"># Perl code: retrieve a list from the leaf of a hash containing hashes that contain arrays</span>
<span class="k">my</span><span class="w"> </span><span class="nv">@trans_verbs</span><span class="w"> </span><span class="o">=</span><span class="w"> </span><span class="nv">@</span><span class="p">{</span><span class="w"> </span><span class="nv">$dictionary</span><span class="p">{</span><span class="w"> </span><span class="s">'verb'</span><span class="w"> </span><span class="p">}{</span><span class="w"> </span><span class="s">'transitive'</span><span class="w"> </span><span class="p">}</span><span class="w"> </span><span class="p">};</span>
</pre></div>
<p>This complexity has no equivalent either in common use of natural language or in other programming languages, and it causes high <a href="Cognitive_load" title="Cognitive load">cognitive load</a> when writing code to manipulate complex data structures. This is the same code in Raku:
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="c1"># Raku code: retrieve a list from the leaf of a hash containing hashes that contain arrays</span>
<span class="k">my</span> <span class="nv">@trans_verbs</span> = <span class="nv">%dictionary&lt;verb&gt;&lt;transitive&gt;&lt;&gt;</span>;
</pre></div>
<div class="mw-heading mw-heading3"><h3 id="Object-oriented_programming">Object-oriented programming</h3></div>
<p>Perl supports <a href="Object-oriented_programming" title="Object-oriented programming">object-oriented programming</a> via a mechanism known as <i>blessing</i>. Any reference can be blessed into being an object of a particular class. A blessed object can have <a href="Method_(computer_science)" class="mw-redirect" title="Method (computer science)">methods</a> invoked on it using the "arrow syntax" which will cause Perl to locate or "dispatch" an appropriate <a href="Subroutine" class="mw-redirect" title="Subroutine">subroutine</a> by name, and call it with the blessed variable as its first argument.
</p><p>While extremely powerful, it makes the most common case of object orientation, a <a href="Struct" class="mw-redirect" title="Struct">struct</a>-like object with some associated code, unnecessarily difficult. In addition, because Perl can make no assumptions about the <a href="Object_model" title="Object model">object model</a> in use, method invocation cannot be optimized very well.
</p><p>In the spirit of making the "easy things easy and hard things possible", Raku retains the blessing model and supplies a more robust object model for the common cases.<sup id="cite_ref-37" class="reference"><a href="#cite_note-37"><span class="cite-bracket">[</span>37<span class="cite-bracket">]</span></a></sup> For example, a class to encapsulate a <a href="Cartesian_coordinate_system" title="Cartesian coordinate system">Cartesian</a> <a href="Point_(geometry)" title="Point (geometry)">point</a> could be defined and used this way:
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="k">class</span> <span class="n">Point</span> <span class="k">is</span> <span class="k">rw</span> {
<span class="k">has</span> <span class="nv">$.x</span>;
<span class="k">has</span> <span class="nv">$.y</span>;
<span class="k">method</span> <span class="n">distance</span>( <span class="n">Point</span> <span class="nv">$p</span> ) {
<span class="nb">sqrt</span>((<span class="nv">$!x</span> - <span class="nv">$p</span>.<span class="nb">x</span>) ** <span class="mi">2</span> + (<span class="nv">$!y</span> - <span class="nv">$p</span>.<span class="n">y</span>) ** <span class="mi">2</span>)
}
<span class="k">method</span> <span class="n">distance-to-center</span> {
<span class="nb">self</span>.<span class="n">distance:</span> <span class="n">Point</span>.<span class="nb">new</span>(<span class="nb">x</span> =&gt; <span class="mi">0</span>, <span class="n">y</span> =&gt; <span class="mi">0</span>)
}
}

<span class="k">my</span> <span class="nv">$point</span> = <span class="n">Point</span>.<span class="nb">new</span>( <span class="nb">x</span> =&gt; <span class="mf">1.2</span>, <span class="n">y</span> =&gt; -<span class="mf">3.7</span> );
<span class="nb">say</span> <span class="s">"Point's location: ("</span>, <span class="nv">$point</span>.<span class="nb">x</span>, <span class="s">', '</span>, <span class="nv">$point</span>.<span class="n">y</span>, <span class="s">')'</span>;
<span class="c1"># OUTPUT: Point's location: (1.2, -3.7)</span>

<span class="c1"># Changing x and y (note methods "x" and "y" used as lvalues):</span>
<span class="nv">$point</span>.<span class="nb">x</span> = <span class="mi">3</span>;
<span class="nv">$point</span>.<span class="n">y</span> = <span class="mi">4</span>;
<span class="nb">say</span> <span class="s">"Point's location: ("</span>, <span class="nv">$point</span>.<span class="nb">x</span>, <span class="s">', '</span>, <span class="nv">$point</span>.<span class="n">y</span>, <span class="s">')'</span>;
<span class="c1"># OUTPUT: Point's location: (3, 4)</span>

<span class="k">my</span> <span class="nv">$other-point</span> = <span class="n">Point</span>.<span class="nb">new</span>(<span class="nb">x</span> =&gt; -<span class="mi">5</span>, <span class="n">y</span> =&gt; <span class="mi">10</span>);
<span class="nv">$point</span>.<span class="n">distance</span>(<span class="nv">$other-point</span>); <span class="c1">#=&gt; 10</span>
<span class="nv">$point</span>.<span class="n">distance-to-center</span>; <span class="c1">#=&gt; 5</span>
</pre></div>
<p>The dot replaces the arrow in a nod to the many other languages (e.g. <a href="C%2B%2B" title="C++">C++</a>, <a href="Java_(programming_language)" title="Java (programming language)">Java</a>, <a href="Python_(programming_language)" title="Python (programming language)">Python</a>, etc.) that have coalesced around dot as the syntax for method invocation.
</p><p>In the terminology of Raku, <code>$.x</code> is called an "attribute". Some languages call these <i>fields </i>or <i>members</i>. The method used to access an attribute is called an "accessor". An auto-accessor method is a method created automatically and named after the attribute's name, as the method <code>x</code> is in the example above. These accessor functions return the value of the attribute. When a class or individual attribute is declared with the <code>is rw</code> modifier (short for "read/write"), the auto-accessors can be passed a new value to set the attribute to, or it can be directly assigned to as an <a href="Value_(computer_science)#lrvalue" title="Value (computer science)">lvalue</a> (as in the example). Auto-accessors can be replaced by user-defined methods, should the programmer desire a richer interface to an attribute. Attributes can only be accessed directly from within a class definition via the <code>$!</code> syntax regardless of how the attributes are declared. All other access must go through the accessor methods.
</p><p>The Raku object system has inspired the <a href="Moose_(Perl)" title="Moose (Perl)">Moose</a> framework that introduces many of Raku's OOP features to Perl.
</p>
<div class="mw-heading mw-heading4"><h4 id="Inheritance,_Roles_and_Classes">Inheritance, Roles and Classes</h4></div>
<p>Inheritance is the technique by which an object or type can re-use code or definitions from existing objects or types. For example, a programmer may want to have a standard type but with an extra attribute. Inheritance in other languages, such as Java, is provided by allowing Classes to be sub-classes of existing classes.
</p><p>Raku provides for inheritance via Classes, which are similar to Classes in other languages, and Roles.
</p><p>Roles in Raku take on the function of <a href="Interface_(Java)" title="Interface (Java)"><i>interfaces</i> in Java</a>, <i><a href="Mixin" title="Mixin">mixins</a></i> in Ruby, and <i><a href="Trait_(computer_science)" class="mw-redirect" title="Trait (computer science)">traits</a></i><sup id="cite_ref-38" class="reference"><a href="#cite_note-38"><span class="cite-bracket">[</span>38<span class="cite-bracket">]</span></a></sup> in <a href="PHP" title="PHP">PHP</a> and in the <a href="Smalltalk" title="Smalltalk">Smalltalk</a> variant <a href="Squeak" title="Squeak">Squeak</a>. These are much like classes, but they provide a safer composition mechanism.<sup id="cite_ref-39" class="reference"><a href="#cite_note-39"><span class="cite-bracket">[</span>39<span class="cite-bracket">]</span></a></sup> These are used to perform composition when used with classes rather than adding to their <a href="Inheritance_(object-oriented_programming)" title="Inheritance (object-oriented programming)">inheritance</a> chain. Roles define nominal types; they provide semantic names for collections of behavior and state. The fundamental difference between a role and a class is that classes can be instantiated; roles are not.<sup id="cite_ref-40" class="reference"><a href="#cite_note-40"><span class="cite-bracket">[</span>40<span class="cite-bracket">]</span></a></sup>
</p><p>Although Roles are distinct from Classes, it is possible to write Raku code that directly instantiates a Role or uses a Role as a type object, Raku will automatically create a class with the same name as the role, making it possible to transparently use a role as if it were a class.<sup id="cite_ref-41" class="reference"><a href="#cite_note-41"><span class="cite-bracket">[</span>41<span class="cite-bracket">]</span></a></sup>
</p><p>Essentially, a role is a bundle of (possibly abstract) methods and attributes that can be added to a class without using inheritance. A role can even be added to an individual object; in this case, Raku will create an anonymous subclass, add the role to the subclass, and change the object's class to the anonymous subclass.
</p><p>For example, a <a href="Dog" title="Dog">Dog</a> is a <a href="Mammal" title="Mammal">Mammal</a> because dogs inherit certain characteristics from Mammals, such as <a href="Mammary_gland" title="Mammary gland">mammary glands</a> and (through Mammal's parent, <a href="Vertebrate" title="Vertebrate">Vertebrate</a>) a <a href="Vertebral_column" class="mw-redirect" title="Vertebral column">backbone</a>. On the other hand, dogs also may have one of several distinct types of behavior, and these behaviours may change over time. For example, a Dog may be a <a href="Pet" title="Pet">Pet</a>, a <a href="Feral" title="Feral">Stray</a> (an abandoned pet will acquire behaviours to survive not associated with a pet), or a <a href="Guide_dog" title="Guide dog">Guide</a> for the blind (guide dogs are trained, so they do not start life as guide dogs). However, these are sets of additional behaviors that can be added to a Dog. It is also possible to describe these behaviors in such a way that they can be usefully applied to other animals, for example, a <a href="Cat" title="Cat">Cat</a> can equally be a Pet or Stray. Hence, Dog and Cat are distinct from each other, while both remain within the more general category Mammal. So Mammal is a Class and Dog and Cat are classes that inherit from Mammal. But the behaviours associated with Pet, Stray, and Guide are Roles that can be added to Classes, or objects instantiated from Classes.
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="k">class</span> <span class="n">Mammal</span> <span class="k">is</span> <span class="n">Vertebrate</span> {
...
}
<span class="k">class</span> <span class="n">Dog</span> <span class="k">is</span> <span class="n">Mammal</span> {
...
}
<span class="k">role</span> <span class="n">Pet</span> {
...
}
<span class="k">role</span> <span class="n">Stray</span> {
...
}
<span class="k">role</span> <span class="n">Guide</span> {
...
}
</pre></div>
<p>Roles are added to a class or object with the <code>does</code> keyword. In order to show inheritance from a class, there is a different keyword <code>is</code>. The keywords reflect the differing meanings of the two features: role composition gives a class the <i>behavior</i> of the role, but doesn't indicate that it is truly the <i>same thing</i> as the role.
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="k">class</span> <span class="n">GuideDog</span> <span class="k">is</span> <span class="n">Dog</span> <span class="k">does</span> <span class="n">Guide</span> {
...
} <span class="c1"># Subclass composes role</span>

<span class="k">my</span> <span class="nv">$dog</span> = <span class="nb">new</span> <span class="n">Dog</span>;
<span class="nv">$dog</span> <span class="k">does</span> <span class="n">Guide</span>; <span class="c1"># Individual object composes role</span>
</pre></div>
<p>Although roles are distinct from classes, both are types, so a role can appear in a variable declaration where one would normally put a class. For example, a Blind role for a Human could include an attribute of type Guide; this attribute could contain a Guide Dog, a <a href="Guide_horse" title="Guide horse">Guide Horse</a>, a Guide Human, or even a Guide Machine.
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="k">class</span> <span class="n">Human</span> {
<span class="k">has</span> <span class="n">Dog</span> <span class="nv">$dog</span>; <span class="c1"># Can contain any kind of Dog, whether it does the</span>
... <span class="c1"># Guide role or not</span>
}
<span class="k">role</span> <span class="n">Blind</span> {
<span class="k">has</span> <span class="n">Guide</span> <span class="nv">$guide</span>; <span class="c1"># Can contain any object that does the Guide role,</span>
... <span class="c1"># whether it is a Dog or something else</span>
}
</pre></div>
<div class="mw-heading mw-heading3"><h3 id="Regular_expressions">Regular expressions</h3></div>
<style data-mw-deduplicate="TemplateStyles:r1236090951">
/* start https://en.wikipedia.org/ */


.mw-parser-output .hatnote{font-style:italic}.mw-parser-output div.hatnote{padding-left:1.6em;margin-bottom:0.5em}.mw-parser-output .hatnote i{font-style:normal}.mw-parser-output .hatnote+link+.hatnote{margin-top:-0.5em}@media print{body.ns-0 .mw-parser-output .hatnote{display:none!important}}


/* end https://en.wikipedia.org/ */
</style><div role="note" class="hatnote navigation-not-searchable">Main article: <a href="Raku_rules" title="Raku rules">Raku rules</a></div>
<p>Perl's <a href="Regular_expression" title="Regular expression">regular expression</a> and string-processing support has always been one of its defining features.<sup id="cite_ref-42" class="reference"><a href="#cite_note-42"><span class="cite-bracket">[</span>42<span class="cite-bracket">]</span></a></sup> Since Perl's pattern-matching constructs have exceeded the capabilities of <a href="Regular_language" title="Regular language">regular language</a> expressions for some time,<sup id="cite_ref-43" class="reference"><a href="#cite_note-43"><span class="cite-bracket">[</span>43<span class="cite-bracket">]</span></a></sup> Raku documentation exclusively refers to them as <i>regexes</i>, distancing the term from the formal definition.
</p><p>Raku provides a superset of Perl features with respect to regexes, folding them into a larger framework called "<a href="Raku_rules" title="Raku rules">rules</a>" which provide the capabilities of <a href="Context-sensitive_language" title="Context-sensitive language">context-sensitive</a> <a href="Parsing" title="Parsing">parsing</a> formalisms (such as the <a href="Syntactic_predicate" title="Syntactic predicate">syntactic predicates</a> of <a href="Parsing_expression_grammar" title="Parsing expression grammar">parsing expression grammars</a> and <a href="ANTLR" title="ANTLR">ANTLR</a>), as well as acting as a <a href="Closure_(computer_science)" class="mw-redirect" title="Closure (computer science)">closure</a> with respect to their <a href="Scope_(programming)" class="mw-redirect" title="Scope (programming)">lexical scope</a>.<sup id="cite_ref-44" class="reference"><a href="#cite_note-44"><span class="cite-bracket">[</span>44<span class="cite-bracket">]</span></a></sup> Rules are introduced with the <code>rule</code> keyword which has a usage quite similar to subroutine definition. Anonymous rules can also be introduced with the <code>regex</code> (or <code>rx</code>) keyword, or they can simply be used inline as regexps were in Perl via the <code>m</code> (matching) or <code>s</code> (substitute) operators.
</p><p>In <i>Apocalypse 5</i>, Larry Wall enumerated 20 problems with "current regex culture". Among these were that Perl's regexes were "too compact and 'cute'", had "too much reliance on too few metacharacters", "little support for named captures", "little support for grammars", and "poor integration with 'real' language".<sup id="cite_ref-45" class="reference"><a href="#cite_note-45"><span class="cite-bracket">[</span>45<span class="cite-bracket">]</span></a></sup>
</p>
<div class="mw-heading mw-heading3"><h3 id="Syntactic_simplification">Syntactic simplification</h3></div>
<p>Some Perl constructs have been changed in Raku, optimized for different syntactic cues for the most common cases. For example, the parentheses (round <a href="Bracket" title="Bracket">brackets</a>) required in <a href="Control_flow" title="Control flow">control flow</a> constructs in Perl are now optional:<sup id="cite_ref-syn04_36-1" class="reference"><a href="#cite_note-syn04-36"><span class="cite-bracket">[</span>36<span class="cite-bracket">]</span></a></sup>
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="k">if</span> <span class="n">is-true</span>() {
<span class="k">for</span> <span class="nv">@array</span> {
...
}
}
</pre></div>
<p>Also, the <code>,</code> (comma) operator is now a list constructor, so enclosing parentheses are no longer required around lists. The code
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="nv">@array</span> = <span class="mi">1</span>, <span class="mi">2</span>, <span class="mi">3</span>, <span class="mi">4</span>;
</pre></div>
<p>now makes <code>@array</code> an array with exactly the elements '1', '2', '3', and '4'.
</p>
<div class="mw-heading mw-heading3"><h3 id="Chained_comparisons">Chained comparisons</h3></div>
<p>Raku allows comparisons to "chain". That is, a sequence of comparisons such as the following is allowed:
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="k">if</span> <span class="mi">20</span> &lt;= <span class="nv">$temperature</span> &lt;= <span class="mi">25</span> {
<span class="nb">say</span> <span class="s">"Room temperature is between 20 and 25!"</span>
}
</pre></div>
<p>This is treated as if each left-to-right comparison were performed on its own, and the result is logically combined via the <code>and</code> operation.
</p>
<div class="mw-heading mw-heading3"><h3 id="Lazy_evaluation">Lazy evaluation</h3></div>
<p>Raku uses the technique of <a href="Lazy_evaluation" title="Lazy evaluation">lazy evaluation</a> of lists that has been a feature of some <a href="Functional_programming" title="Functional programming">functional programming</a> languages such as <a href="Haskell_(programming_language)" class="mw-redirect" title="Haskell (programming language)">Haskell</a>:<sup id="cite_ref-syn9_46-0" class="reference"><a href="#cite_note-syn9-46"><span class="cite-bracket">[</span>46<span class="cite-bracket">]</span></a></sup>
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="nv">@integers</span> = <span class="mi">0</span><span class="o">..</span><span class="n">Inf</span>; <span class="c1"># integers from 0 to infinity</span>
</pre></div>
<p>The code above will not crash by attempting to assign a list of infinite size to the array <code>@integers</code>, nor will it hang indefinitely in attempting to expand the list if a limited number of slots are searched.
</p><p>This simplifies many common tasks in Raku including input/output operations, list transformations, and parameter passing.
</p>
<div class="mw-heading mw-heading3"><h3 id="Gather">Gather</h3></div>
<p>Related to lazy evaluation is the construction of lazy lists using <code>gather</code> and <code>take</code>, behaving somewhat like generators in languages like <a href="Icon_(programming_language)" title="Icon (programming language)">Icon</a> or <a href="Python_(programming_language)" title="Python (programming language)">Python</a>.
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="k">my</span> <span class="nv">$squares</span> = <span class="nb">lazy</span> <span class="k">gather</span> <span class="k">for</span> <span class="mi">0</span><span class="o">..</span><span class="n">Inf</span> {
<span class="nb">take</span> <span class="nv">$_</span> * <span class="nv">$_</span>;
};
</pre></div>
<p><code>$squares</code> will be an infinite list of square numbers, but lazy evaluation of the <code>gather</code> ensures that elements are only computed when they are accessed.
</p>
<div class="mw-heading mw-heading3"><h3 id="Junctions">Junctions</h3></div>
<p>Raku introduces the concept of <i>junctions</i>: values that are composites of other values.<sup id="cite_ref-syn9_46-1" class="reference"><a href="#cite_note-syn9-46"><span class="cite-bracket">[</span>46<span class="cite-bracket">]</span></a></sup> In their simplest form, junctions are created by combining a set of values with junctive <a href="Operator_(programming)" class="mw-redirect" title="Operator (programming)">operators</a>:
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="c1"># Example for | ("any") Junction:</span>
<span class="k">my</span> <span class="nv">$color</span> = <span class="s">'white'</span>;
<span class="k">unless</span> <span class="nv">$color</span> <span class="o">eq</span> <span class="s">'white'</span> | <span class="s">'black'</span> | <span class="s">'gray'</span> | <span class="s">'grey'</span> {
<span class="nb">die</span> <span class="s">"Color printing not supported\n"</span>;
}

<span class="c1"># Example for &amp; ("all") Junction:</span>
<span class="k">my</span> <span class="nv">$password</span> = <span class="s">'secret!123'</span>;
<span class="k">if</span> <span class="nv">$password</span> ~~<span class="sr"> /&lt;:alpha&gt;/</span> &amp; /<span class="s">&lt;:digit&gt;</span>/ &amp; /<span class="s">&lt;:punct&gt;</span>/ {
<span class="nb">say</span> <span class="s">"Your password is reasonably secure"</span>;
}
</pre></div>
<p><code>|</code> indicates a value which is equal to either its left- <i>or</i> right-hand arguments. <code>&amp;</code> indicates a value which is equal to both its left- <i>and</i> right-hand arguments. These values can be used in any code that would use a normal value. Operations performed on a junction act on all members of the junction equally, and combine according to the junctive operator. So, <code>("apple"|"banana") ~ "s"</code> would yield <code>"apples"|"bananas"</code>. In comparisons, junctions return a single true or false result for the comparison. "<code>any</code>" junctions return true if the comparison is true for any one of the elements of the junction. "<code>all</code>" junctions return true if the comparison is true for all of the elements of the junction.
</p><p>Junctions can also be used to more richly augment the type system by introducing a style of <a href="Generic_programming" title="Generic programming">generic programming</a> that is constrained to junctions of types:
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="k">subset</span> <span class="n">Color</span> <span class="nb">of</span> <span class="nb">Any</span> <span class="n">where</span> <span class="n">RGB_Color</span> | <span class="n">CMYK_Color</span>;
<span class="k">sub</span> <span class="n">get_tint</span>(<span class="n">Color</span> <span class="nv">$color</span>, <span class="nb">Num</span> <span class="nv">$opacity</span>) {
...
}
</pre></div>
<div class="mw-heading mw-heading3"><h3 id="Macros">Macros</h3></div>
<p>In low-level languages, the concept of <a href="Macro_(computer_science)" title="Macro (computer science)">macros</a> has become synonymous with textual substitution of source-code due to the widespread use of the <a href="C_preprocessor" title="C preprocessor">C preprocessor</a>. However, high-level languages such as <a href="Lisp_programming_language" class="mw-redirect" title="Lisp programming language">Lisp</a> pre-dated C in their use of macros that were far more powerful.<sup id="cite_ref-47" class="reference"><a href="#cite_note-47"><span class="cite-bracket">[</span>47<span class="cite-bracket">]</span></a></sup> It is this Lisp-like macro concept that Raku will take advantage of.<sup id="cite_ref-syn6_35-2" class="reference"><a href="#cite_note-syn6-35"><span class="cite-bracket">[</span>35<span class="cite-bracket">]</span></a></sup> The power of this sort of macro stems from the fact that it operates on the program as a high-level <a href="Data_structure" title="Data structure">data structure</a>, rather than as simple text, and has the full capabilities of the programming language at its disposal.
</p><p>A Raku macro definition will look like a subroutine or method definition, and it can operate on unparsed strings, an <a href="Abstract_syntax_tree" title="Abstract syntax tree">AST</a> representing pre-parsed code, or a combination of the two. A macro definition would look like this:<sup id="cite_ref-macros_48-0" class="reference"><a href="#cite_note-macros-48"><span class="cite-bracket">[</span>48<span class="cite-bracket">]</span></a></sup>
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="n">macro</span> <span class="n">hello</span>(<span class="nv">$what</span>) {
<span class="n">quasi</span> { <span class="nb">say</span> <span class="s">"Hello { {{{$what}}} }"</span> };
}
</pre></div>
<p>In this particular example, the macro is no more complex than a C-style textual substitution, but because parsing of the macro parameter occurs before the macro operates on the calling code, diagnostic messages would be far more informative. However, because the body of a macro is executed at <a href="Compile_time" title="Compile time">compile time</a> each time it is used, many techniques of <a href="Optimization_(computer_science)" class="mw-redirect" title="Optimization (computer science)">optimization</a> can be employed. It is even possible to eliminate complex computations from resulting programs by performing the work at compile-time.
</p>
<div class="mw-heading mw-heading3"><h3 id="Identifiers">Identifiers</h3></div>
<p>In Perl, identifier names can use the ASCII alphanumerics and underscores also available in other languages. In Raku, the alphanumerics can include most Unicode characters. In addition, hyphens and apostrophes can be used (with certain restrictions, such as not being followed by a digit). Using hyphens instead of underscores to separate words in a name leads to a style of naming called "<a href="Kebab_case" class="mw-redirect" title="Kebab case">kebab case</a>".
</p>
<div class="mw-heading mw-heading2"><h2 id="Examples">Examples</h2></div>
<div class="mw-heading mw-heading3"><h3 id="Hello_world">Hello world</h3></div>
<p>The <a href="Hello_world_program" class="mw-redirect" title="Hello world program">hello world program</a> is a common program used to introduce a language. In Raku, hello world is:
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="nb">say</span> <span class="s">'Hello, world'</span>;
</pre></div>
<p>— though <a href="There_is_more_than_one_way_to_do_it" class="mw-redirect" title="There is more than one way to do it">there is more than one way to do it</a>.
</p>
<div class="mw-heading mw-heading3"><h3 id="Factorial">Factorial</h3></div>
<p>The <a href="Factorial" title="Factorial">factorial</a> function in Raku, defined in a few different ways:
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="c1"># Using recursion (with `if\else` construct)</span>
<span class="k">sub</span> <span class="n">fact</span>( <span class="nb">UInt</span> <span class="nv">$n</span> --&gt; <span class="nb">UInt</span> ) {
<span class="k">if</span> <span class="nv">$n</span> == <span class="mi">0</span> { <span class="mi">1</span> }
<span class="k">else</span> { <span class="nv">$n</span> * <span class="n">fact</span>(<span class="nv">$n-1</span>) }
}

<span class="c1"># Using recursion (with `if` as statement modifier)</span>
<span class="k">sub</span> <span class="n">fact</span>( <span class="nb">UInt</span> <span class="nv">$n</span> --&gt; <span class="nb">UInt</span> ) {
<span class="k">return</span> <span class="mi">1</span> <span class="k">if</span> <span class="nv">$n</span> == <span class="mi">0</span>;
<span class="k">return</span> <span class="nv">$n</span> * <span class="n">fact</span>(<span class="nv">$n-1</span>);
}

<span class="c1"># Using recursion (with `when` construct)</span>
<span class="k">sub</span> <span class="n">fact</span>( <span class="nb">UInt</span> <span class="nv">$n</span> --&gt; <span class="nb">UInt</span> ) {
<span class="k">when</span> <span class="nv">$n</span> == <span class="mi">0</span> { <span class="mi">1</span> }
<span class="k">default</span> { <span class="nv">$n</span> * <span class="n">fact</span>(<span class="nv">$n-1</span>) }
}

<span class="c1"># Using the ternary operator</span>
<span class="k">sub</span> <span class="n">fact</span>( <span class="nb">UInt</span> <span class="nv">$n</span> --&gt; <span class="nb">UInt</span> ) {
<span class="nv">$n</span> == <span class="mi">0</span>&nbsp;?? <span class="mi">1</span>&nbsp;!! <span class="nv">$n</span> * <span class="n">fact</span>(<span class="nv">$n-1</span>)
}

<span class="c1"># Using multiple dispatch</span>
<span class="k">multi</span> <span class="n">fact</span>(<span class="mi">0</span>) { <span class="mi">1</span> }
<span class="k">multi</span> <span class="n">fact</span>( <span class="nb">UInt</span> <span class="nv">$n</span> --&gt; <span class="nb">UInt</span> ) {
<span class="nv">$n</span> * <span class="n">fact</span>(<span class="nv">$n</span> - <span class="mi">1</span>)
}

<span class="c1"># Using the reduction metaoperator</span>
<span class="k">sub</span> <span class="n">fact</span>( <span class="nb">UInt</span> <span class="nv">$n</span> --&gt; <span class="nb">UInt</span> ) {
[*] <span class="mi">1</span>..<span class="nv">$n</span>
}

<span class="c1"># Creating a factorial operator and using the reduction metaoperator</span>
<span class="k">sub</span> <span class="n">postfix:</span><span class="s">&lt;!&gt;( UInt $n --&gt;</span> <span class="nb">UInt</span> ) { [*] <span class="mi">1</span>..<span class="nv">$n</span> }

<span class="c1"># Using `state` declarator to create a memoized factorial</span>
<span class="k">sub</span> <span class="n">fact</span>( <span class="nb">UInt</span> <span class="nv">$n</span> --&gt; <span class="nb">UInt</span> ) {
<span class="k">state</span> <span class="nv">%known</span> = <span class="mi">0</span> =&gt; <span class="mi">1</span>;
<span class="k">return</span> <span class="nv">%known</span>{<span class="nv">$n</span>} <span class="k">if</span> <span class="nv">%known</span>{<span class="nv">$n</span>}:<span class="n">exists</span>;
<span class="nv">%known</span>{<span class="nv">$n</span>} = <span class="nv">$n</span> * <span class="n">fact</span>(<span class="nv">$n-1</span>);
<span class="k">return</span> <span class="nv">%known</span>{<span class="nv">$n</span>};
}
</pre></div>
<div class="mw-heading mw-heading3"><h3 id="Quicksort">Quicksort</h3></div>
<p><a href="Quicksort" title="Quicksort">Quicksort</a> is a well-known sorting algorithm. A working implementation<sup id="cite_ref-49" class="reference"><a href="#cite_note-49"><span class="cite-bracket">[</span>a<span class="cite-bracket">]</span></a></sup> using the functional programming paradigm can be succinctly written in Raku:
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="c1"># Empty list sorts to the empty list</span>
<span class="k">multi</span> <span class="n">quicksort</span>([]) { () }

<span class="c1"># Otherwise, extract first item as pivot...</span>
<span class="k">multi</span> <span class="n">quicksort</span>([<span class="nv">$pivot</span>, *<span class="nv">@rest</span>]) {
<span class="c1"># Partition.</span>
<span class="k">my</span> <span class="nv">@before</span> = <span class="nv">@rest</span>.<span class="nb">grep</span>(* &lt; <span class="nv">$pivot</span>);
<span class="k">my</span> <span class="nv">@after</span> = <span class="nv">@rest</span>.<span class="nb">grep</span>(* &gt;= <span class="nv">$pivot</span>);

<span class="c1"># Sort the partitions.</span>
<span class="nb">flat</span> (<span class="n">quicksort</span>(<span class="nv">@before</span>), <span class="nv">$pivot</span>, <span class="n">quicksort</span>(<span class="nv">@after</span>))
}
</pre></div>
<style data-mw-deduplicate="TemplateStyles:r1239543626">
/* start https://en.wikipedia.org/ */


.mw-parser-output .reflist{margin-bottom:0.5em;list-style-type:decimal}@media screen{.mw-parser-output .reflist{font-size:90%}}.mw-parser-output .reflist .references{font-size:100%;margin-bottom:0;list-style-type:inherit}.mw-parser-output .reflist-columns-2{column-width:30em}.mw-parser-output .reflist-columns-3{column-width:25em}.mw-parser-output .reflist-columns{margin-top:0.3em}.mw-parser-output .reflist-columns ol{margin-top:0}.mw-parser-output .reflist-columns li{page-break-inside:avoid;break-inside:avoid-column}.mw-parser-output .reflist-upper-alpha{list-style-type:upper-alpha}.mw-parser-output .reflist-upper-roman{list-style-type:upper-roman}.mw-parser-output .reflist-lower-alpha{list-style-type:lower-alpha}.mw-parser-output .reflist-lower-greek{list-style-type:lower-greek}.mw-parser-output .reflist-lower-roman{list-style-type:lower-roman}


/* end https://en.wikipedia.org/ */
</style><div class="reflist reflist-lower-alpha">
<div class="mw-references-wrap"><ol class="references">
<li id="cite_note-49"><span class="mw-cite-backlink"><b><a href="#cite_ref-49">^</a></b></span> <span class="reference-text">Unless the implementation does something fancy and mysterious behind the scenes, the maximal possible recursion depth is the length of the list, making this implementation unsuitable for big data. Recursion depth can be limited to <code>log2(list_length)</code> by iterating into the larger of partitions <code>before</code> and <code>after</code>, and only recursing into the smaller partition.</span>
</li>
</ol></div></div>
<div class="mw-heading mw-heading3"><h3 id="Tower_of_Hanoi">Tower of Hanoi</h3></div>
<p><a href="Tower_of_Hanoi" title="Tower of Hanoi">Tower of Hanoi</a> is often used to introduce recursive programming in computer science. This implementation uses Raku's multi-dispatch mechanism and parametric constraints:
</p>
<div class="mw-highlight mw-highlight-lang-raku mw-content-ltr" dir="ltr"><pre><span class="k">multi</span> <span class="k">sub</span> <span class="n">hanoi</span>(<span class="mi">0</span>, $, $, $) { } <span class="c1"># No disk, so do not do anything</span>
<span class="k">multi</span> <span class="k">sub</span> <span class="n">hanoi</span>(<span class="nv">$n</span>, <span class="nv">$a</span> = <span class="s">'A'</span>, <span class="nv">$b</span> = <span class="s">'B'</span>, <span class="nv">$c</span> = <span class="s">'C'</span>) { <span class="c1"># Start with $n disks and three pegs A, B, C</span>
<span class="n">hanoi</span> <span class="nv">$n</span> - <span class="mi">1</span>, <span class="nv">$a</span>, <span class="nv">$c</span>, <span class="nv">$b</span>; <span class="c1"># firstly move top $n - 1 disks from A to B</span>
<span class="nb">say</span> <span class="s">"Move disk $n from peg $a to peg $c"</span>; <span class="c1"># then move last disk from A to C</span>
<span class="n">hanoi</span> <span class="nv">$n</span> - <span class="mi">1</span>, <span class="nv">$b</span>, <span class="nv">$a</span>, <span class="nv">$c</span>; <span class="c1"># lastly move $n - 1 disks from B to C</span>
}
</pre></div>
<div class="mw-heading mw-heading2"><h2 id="Books">Books</h2></div>
<p>In the history of Raku there were two waves of book writing. The first wave followed the initial announcement of Perl 6 in 2000. Those books reflect the state of the design of the language of that time, and contain mostly outdated material. The second wave, that followed the announcement of Version 1.0 in 2015, includes several books that have already been published and some others that are in the process of being written.
</p>
<div class="mw-heading mw-heading3"><h3 id="Books_published_before_Perl_6_version_1.0_(known_as_version_6.c)">Books published before Perl 6 version 1.0 (known as version 6.c)</h3></div>
<ul><li><style data-mw-deduplicate="TemplateStyles:r1238218222">
/* start https://en.wikipedia.org/ */


.mw-parser-output cite.citation{font-style:inherit;word-wrap:break-word}.mw-parser-output .citation q{quotes:"\"""\"""'""'"}.mw-parser-output .citation:target{background-color:rgba(0,127,255,0.133)}.mw-parser-output .id-lock-free.id-lock-free a{background:url("./mw/Lock-green.svg")right 0.1em center/9px no-repeat}.mw-parser-output .id-lock-limited.id-lock-limited a,.mw-parser-output .id-lock-registration.id-lock-registration a{background:url("./mw/Lock-gray-alt-2.svg")right 0.1em center/9px no-repeat}.mw-parser-output .id-lock-subscription.id-lock-subscription a{background:url("./mw/Lock-red-alt-2.svg")right 0.1em center/9px no-repeat}.mw-parser-output .cs1-ws-icon a{background:url("./mw/Wikisource-logo.svg")right 0.1em center/12px no-repeat}body:not(.skin-timeless):not(.skin-minerva) .mw-parser-output .id-lock-free a,body:not(.skin-timeless):not(.skin-minerva) .mw-parser-output .id-lock-limited a,body:not(.skin-timeless):not(.skin-minerva) .mw-parser-output .id-lock-registration a,body:not(.skin-timeless):not(.skin-minerva) .mw-parser-output .id-lock-subscription a,body:not(.skin-timeless):not(.skin-minerva) .mw-parser-output .cs1-ws-icon a{background-size:contain;padding:0 1em 0 0}.mw-parser-output .cs1-code{color:inherit;background:inherit;border:none;padding:inherit}.mw-parser-output .cs1-hidden-error{display:none;color:var(--color-error,#d33)}.mw-parser-output .cs1-visible-error{color:var(--color-error,#d33)}.mw-parser-output .cs1-maint{display:none;color:#085;margin-left:0.3em}.mw-parser-output .cs1-kern-left{padding-left:0.2em}.mw-parser-output .cs1-kern-right{padding-right:0.2em}.mw-parser-output .citation .mw-selflink{font-weight:inherit}@media screen{.mw-parser-output .cs1-format{font-size:95%}html.skin-theme-clientpref-night .mw-parser-output .cs1-maint{color:#18911f}}@media screen and (prefers-color-scheme:dark){html.skin-theme-clientpref-os .mw-parser-output .cs1-maint{color:#18911f}}


/* end https://en.wikipedia.org/ */
</style><cite id="CITEREFRandalSugalskiTötsch2003" class="citation book cs1">Randal, Allison; Sugalski, Dan; Tötsch, Leopold (2003). <i>Perl 6 Essentials</i> (1st&nbsp;ed.). O'Reilly Media. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-0-596-00499-6</bdi>.</cite></li>
<li><cite id="CITEREFRandalSugalskiTötsch2004" class="citation book cs1">Randal, Allison; Sugalski, Dan; Tötsch, Leopold (2004). <a rel="nofollow" class="external text" href="http://shop.oreilly.com/product/9780596007379.do"><i>Perl 6 and Parrot Essentials</i></a> (2nd&nbsp;ed.). O'Reilly Media. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-0-596-00737-9</bdi>.</cite></li>
<li><cite id="CITEREFWalters2004" class="citation book cs1">Walters, Scott (15 December 2004). <a rel="nofollow" class="external text" href="http://www.apress.com/us/book/9781590593950"><i>Perl 6 Now: The Core Ideas Illustrated with Perl 5</i></a>. Expert's Voice in Open Source. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-1-59059-395-0</bdi>.</cite></li></ul>
<p>Also, a book dedicated to one of the first Perl 6 virtual machines, Parrot, was published in 2009.
</p>
<ul><li><cite id="CITEREFRandalWhitworth2009" class="citation book cs1">Randal, Allison; Whitworth, Andrew (15 June 2009). <a rel="nofollow" class="external text" href="https://web.archive.org/web/20161018020706/http://www.onyxneon.com/books/pir/index.html"><i>Parrot Developer's Guide: Pir</i></a>. Onyx Neon Press. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-0-9779201-2-9</bdi>. Archived from <a rel="nofollow" class="external text" href="http://onyxneon.com/books/pir/index.html">the original</a> on 18 October 2016<span class="reference-accessdate">. Retrieved <span class="nowrap">24 July</span> 2017</span>.</cite></li></ul>
<div class="mw-heading mw-heading3"><h3 id="Books_published_after_Perl_6_version_1.0_(known_as_version_6.c)">Books published after Perl 6 version 1.0 (known as version 6.c)</h3></div>
<ul><li><cite id="CITEREFShitov2017" class="citation book cs1">Shitov, Andrew (2017). <a rel="nofollow" class="external text" href="https://andrewshitov.com/perl6-at-a-glance/"><i>Perl 6 at a Glance</i></a>. Amazon Digital Services LLC - Kdp. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-90-821568-3-6</bdi>.</cite></li>
<li><cite id="CITEREFRosenfeldDowney2017" class="citation book cs1">Rosenfeld, Laurent; Downey, Allen B. (2017). <a rel="nofollow" class="external text" href="http://shop.oreilly.com/product/0636920065883.do"><i>Think Perl 6</i></a>. O'Reilly Media. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-1-4919-8055-2</bdi>.</cite></li>
<li><cite id="CITEREFMerelo2017" class="citation book cs1">Merelo, J. J. (9 July 2017). <a rel="nofollow" class="external text" href="https://github.com/JJ/perl6em/tree/master/docs"><i>Learning to program with Perl 6: First Steps: Getting into programming without leaving the command line</i></a>. Learning to Program with Perl. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-1-5217-9578-1</bdi>.</cite></li>
<li><cite id="CITEREFLenz2017" class="citation book cs1">Lenz, Moritz (27 July 2017). <a rel="nofollow" class="external text" href="https://www.apress.com/us/book/9781484228982"><i>Perl 6 Fundamentals</i></a>. Apress. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-1-4842-2898-2</bdi>.</cite></li>
<li><cite id="CITEREFShitov2017" class="citation book cs1">Shitov, Andrew (7 September 2017). <a rel="nofollow" class="external text" href="https://www.packtpub.com/application-development/perl-6-deep-dive"><i>Perl 6 Deep Dive</i></a>. Packt Publishing, Limited. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-1-78728-204-9</bdi>.</cite></li>
<li><cite id="CITEREFShitov2017" class="citation book cs1">Shitov, Andrew (2017). <a rel="nofollow" class="external text" href="https://andrewshitov.com/using-perl6/"><i>Using Perl 6</i></a>. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-90-821568-1-2</bdi>.</cite></li>
<li><cite id="CITEREFSzabo2017" class="citation book cs1">Szabo, Gabor (3 December 2017). <a rel="nofollow" class="external text" href="https://leanpub.com/bailador"><i>Web Application Development in Perl 6</i></a>. Author.</cite></li>
<li><cite id="CITEREFLenz2017" class="citation book cs1">Lenz, Moritz (4 December 2017). <a rel="nofollow" class="external text" href="https://www.apress.com/us/book/9781484232279"><i>Parsing with Perl 6 Regexes and Grammars: A Recursive Descent into Parsing</i></a>. Apress. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-1-4842-3228-6</bdi>.</cite></li>
<li><cite id="CITEREFFoy2018" class="citation book cs1">Foy, Brian D. (2018). <a rel="nofollow" class="external text" href="http://shop.oreilly.com/product/0636920062776.do"><i>Learning Perl 6</i></a>. O'Reilly Media. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-1-4919-7768-2</bdi>.</cite></li></ul>
<div class="mw-heading mw-heading3"><h3 id="Books_published_with_the_new_Raku_name">Books published with the new Raku name</h3></div>
<ul><li><cite id="CITEREFShitov2019" class="citation book cs1">Shitov, Andrew (13 October 2019). <a rel="nofollow" class="external text" href="https://andrewshitov.com/2019/10/13/using-raku-the-free-book/"><i>Using Raku: 100 Programming Challenges Solved in the Raku Programming Language</i></a> (2nd&nbsp;ed.). Suzi K Edwards. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-90-821568-8-1</bdi>.</cite></li>
<li><cite id="CITEREFShitov2019" class="citation book cs1">Shitov, Andrew (18 October 2019). <a rel="nofollow" class="external text" href="https://andrewshitov.com/2019/10/18/raku-one-liners-a-free-book/"><i>Raku One-Liners: Getting the Most of Raku's Expressive Syntax for Your Daily Routines</i></a>. Amazon Digital Services LLC - Kdp. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-90-821568-9-8</bdi>.</cite></li>
<li><cite id="CITEREFLenz2020" class="citation book cs1">Lenz, Moritz (6 September 2020). <a rel="nofollow" class="external text" href="https://link.springer.com/book/10.1007/978-1-4842-6109-5"><i>Raku Fundamentals: A Primer with Examples, Projects, and Case Studies</i></a>. Apress. <a href="Doi_(identifier)" class="mw-redirect" title="Doi (identifier)">doi</a>:<a rel="nofollow" class="external text" href="https://doi.org/10.1007%2F978-1-4842-6109-5">10.1007/978-1-4842-6109-5</a>. <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-1-4842-6108-8</bdi>.</cite></li></ul>
<div class="mw-heading mw-heading2"><h2 id="References">References</h2></div>
<div class="reflist">
<div class="mw-references-wrap mw-references-columns"><ol class="references">
<li id="cite_note-camelia-1"><span class="mw-cite-backlink">^ <a href="#cite_ref-camelia_1-0"><sup><i><b>a</b></i></sup></a> <a href="#cite_ref-camelia_1-1"><sup><i><b>b</b></i></sup></a></span> <span class="reference-text"><cite id="CITEREFJackson2010" class="citation web cs1">Jackson, Joab (23 July 2010). <a rel="nofollow" class="external text" href="http://www.infoworld.com/d/open-source/perl-creator-hints-imminent-release-long-awaited-perl-6-445">"Perl creator hints at imminent release of long-awaited Perl 6"</a>. IDG News Service<span class="reference-accessdate">. Retrieved <span class="nowrap">8 February</span> 2015</span>.</cite></span>
</li>
<li id="cite_note-2"><span class="mw-cite-backlink"><b><a href="#cite_ref-2">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="http://blogs.perl.org/users/zoffix_znet/2018/11/announce-raku-perl-6-diwali-6d-language-specification-release.html">"Announce: Raku Perl 6 'Diwali' 6.d Language Specification Release"</a>. <i>blogs.perl.org</i>. Zoffix Znet. 5 November 2018<span class="reference-accessdate">. Retrieved <span class="nowrap">19 August</span> 2022</span>.</cite></span>
</li>
<li id="cite_note-3"><span class="mw-cite-backlink"><b><a href="#cite_ref-3">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://docs.raku.org/language/filename-extensions">"Filename extensions"</a>. <i>Raku Documentation</i>.</cite></span>
</li>
<li id="cite_note-4"><span class="mw-cite-backlink"><b><a href="#cite_ref-4">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://web.archive.org/web/20120121145808/http://www.perlfoundation.org/perl6/index.cgi?glossary_of_terms_and_jargon">"Glossary of Terms and Jargon"</a>. <i>Perl Foundation Perl 6 Wiki</i>. <a href="The_Perl_Foundation" class="mw-redirect" title="The Perl Foundation">The Perl Foundation</a>. 28 February 2011. Archived from <a rel="nofollow" class="external text" href="http://www.perlfoundation.org/perl6/index.cgi?glossary_of_terms_and_jargon">the original</a> on 21 January 2012<span class="reference-accessdate">. Retrieved <span class="nowrap">8 February</span> 2015</span>.</cite></span>
</li>
<li id="cite_note-Tang2010-5"><span class="mw-cite-backlink">^ <a href="#cite_ref-Tang2010_5-0"><sup><i><b>a</b></i></sup></a> <a href="#cite_ref-Tang2010_5-1"><sup><i><b>b</b></i></sup></a></span> <span class="reference-text"><cite id="CITEREF唐鳳,_a.k.a._Audrey_Tang2010" class="citation web cs1">唐鳳, a.k.a. <a href="Audrey_Tang" title="Audrey Tang">Audrey Tang</a> (21 April 2010). <a rel="nofollow" class="external text" href="http://pugs.blogs.com/pugs/2010/04/how-to-implement-perl-6-in-10.html">"How to Implement Perl 6 in '10"</a>.</cite></span>
</li>
<li id="cite_note-6"><span class="mw-cite-backlink"><b><a href="#cite_ref-6">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="http://www.perl.org/about.html">"About Perl"</a>. perl.org<span class="reference-accessdate">. Retrieved <span class="nowrap">11 June</span> 2020</span>. <q>"Perl" is a family of languages, "Raku" (formerly known as "Perl 6") is part of the family, but it is a separate language which has its own development team. Its existence has no significant impact on the continuing development of "Perl".</q></cite></span>
</li>
<li id="cite_note-renamed-7"><span class="mw-cite-backlink"><b><a href="#cite_ref-renamed_7-0">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://lwn.net/Articles/802329/">"Perl 6 renamed to Raku"</a>. <a href="LWN.net" title="LWN.net">LWN.net</a>. 15 October 2019<span class="reference-accessdate">. Retrieved <span class="nowrap">16 October</span> 2019</span>.</cite></span>
</li>
<li id="cite_note-8"><span class="mw-cite-backlink"><b><a href="#cite_ref-8">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://news.perlfoundation.org/post/tpf-response-raku-rename">"TPF response to Raku rename"</a>. 29 October 2019.</cite></span>
</li>
<li id="cite_note-9"><span class="mw-cite-backlink"><b><a href="#cite_ref-9">^</a></b></span> <span class="reference-text"><cite id="CITEREFBiancuzziWarden2009" class="citation book cs1">Biancuzzi, Federico; Warden, Shane (2009). <a rel="nofollow" class="external text" href="https://books.google.com/books?id=yB1WwURwBUQC&amp;q=%22In%20Perl%206%2C%20we%20decided%20it%20would%20be%20better%20to%20fix%20the%20language%20than%20fix%20the%20user%22"><i>Masterminds of Programming: Conversations with the Creators of Major Programming Languages</i></a>. "O'Reilly Media, Inc.". <a href="ISBN_(identifier)" class="mw-redirect" title="ISBN (identifier)">ISBN</a>&nbsp;<bdi>978-0596515171</bdi>.</cite></span>
</li>
<li id="cite_note-10"><span class="mw-cite-backlink"><b><a href="#cite_ref-10">^</a></b></span> <span class="reference-text"><cite id="CITEREFKline,_Joe2000" class="citation web cs1">Kline, Joe (21 August 2000). <a rel="nofollow" class="external text" href="http://www.perl.com/pub/a/2000/08/tpc4.html">"Report from the Perl Conference"</a>.</cite></span>
</li>
<li id="cite_note-11"><span class="mw-cite-backlink"><b><a href="#cite_ref-11">^</a></b></span> <span class="reference-text"><cite id="CITEREFWall2000" class="citation web cs1"><a href="Larry_Wall" title="Larry Wall">Wall, Larry</a> (2000). <a rel="nofollow" class="external text" href="http://www.perl.com/pub/a/2000/10/23/soto2000.html">"State of the Onion 2000"</a>. O'Reilly Network.</cite></span>
</li>
<li id="cite_note-12"><span class="mw-cite-backlink"><b><a href="#cite_ref-12">^</a></b></span> <span class="reference-text"><cite id="CITEREFThe_Perl_Foundation2000" class="citation web cs1">The Perl Foundation (2000). <a rel="nofollow" class="external text" href="https://web.archive.org/web/20210726035820/https://raku.org/archive/rfc/meta/">"About Perl 6 RFCs"</a>. Archived from <a rel="nofollow" class="external text" href="https://raku.org/archive/rfc/meta/">the original</a> on 26 July 2021<span class="reference-accessdate">. Retrieved <span class="nowrap">16 May</span> 2020</span>.</cite></span>
</li>
<li id="cite_note-apoc1-13"><span class="mw-cite-backlink"><b><a href="#cite_ref-apoc1_13-0">^</a></b></span> <span class="reference-text"><cite id="CITEREFWall2001" class="citation web cs1"><a href="Larry_Wall" title="Larry Wall">Wall, Larry</a> (2 April 2001). <a rel="nofollow" class="external text" href="https://www.perl.com/pub/2001/04/02/wall.html/">"Apocalypse 1: The Ugly, the Bad, and the Good"</a>.</cite></span>
</li>
<li id="cite_note-14"><span class="mw-cite-backlink"><b><a href="#cite_ref-14">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://github.com/Raku/roast">"Raku test suite"</a>. <i><a href="GitHub" title="GitHub">GitHub</a></i>. 2019.</cite></span>
</li>
<li id="cite_note-syn-15"><span class="mw-cite-backlink"><b><a href="#cite_ref-syn_15-0">^</a></b></span> <span class="reference-text"><cite id="CITEREFWallThe_Perl_6_designers2015" class="citation web cs1"><a href="Larry_Wall" title="Larry Wall">Wall, Larry</a>; The Perl 6 designers (2015). <a rel="nofollow" class="external text" href="https://design.raku.org/">"Perl 6 Design Documents"</a>.</cite><span class="cs1-maint citation-comment"><code class="cs1-code">{{cite web}}</code>: CS1 maint: numeric names: authors list (link)</span></span>
</li>
<li id="cite_note-exegeses-16"><span class="mw-cite-backlink"><b><a href="#cite_ref-exegeses_16-0">^</a></b></span> <span class="reference-text"><cite id="CITEREFThe_Perl_Foundation2001" class="citation web cs1">The Perl Foundation (2001). <a rel="nofollow" class="external text" href="https://web.archive.org/web/20210726035822/https://raku.org/archive/doc/exegesis.html">"Exegeses"</a>. Archived from <a rel="nofollow" class="external text" href="https://raku.org/archive/doc/exegesis.html">the original</a> on 26 July 2021<span class="reference-accessdate">. Retrieved <span class="nowrap">16 May</span> 2020</span>.</cite></span>
</li>
<li id="cite_note-lists-17"><span class="mw-cite-backlink"><b><a href="#cite_ref-lists_17-0">^</a></b></span> <span class="reference-text"><cite id="CITEREFThe_Raku_Programming_Language2022" class="citation web cs1">The Raku Programming Language (2022). <a rel="nofollow" class="external text" href="https://web.archive.org/web/20200812025211/https://raku.org/archive/lists/">"Raku Community"</a>. Archived from <a rel="nofollow" class="external text" href="https://raku.org/archive/lists/">the original</a> on 12 August 2020<span class="reference-accessdate">. Retrieved <span class="nowrap">16 May</span> 2020</span>.</cite></span>
</li>
<li id="cite_note-18"><span class="mw-cite-backlink"><b><a href="#cite_ref-18">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://github.com/raku">"Raku"</a>. <i>GitHub</i><span class="reference-accessdate">. Retrieved <span class="nowrap">19 August</span> 2022</span>.</cite></span>
</li>
<li id="cite_note-camelia-eyes-19"><span class="mw-cite-backlink"><b><a href="#cite_ref-camelia-eyes_19-0">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://irclog.perlgeek.de/perl6/2016-01-15#i_11894111">"Larry Wall in IRC chat log"</a>. 15 January 2016<span class="reference-accessdate">. Retrieved <span class="nowrap">10 November</span> 2017</span>.</cite></span>
</li>
<li id="cite_note-camelia-purpose-20"><span class="mw-cite-backlink"><b><a href="#cite_ref-camelia-purpose_20-0">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://github.com/perl6/mu/blob/aaa173d49c8ba681628739e96ed28fdb921211ec/misc/camelia.txt#L78-L80">"Archived "Logo considerations" email from Larry Wall"</a>. <i><a href="GitHub" title="GitHub">GitHub</a></i>. 24 March 2009<span class="reference-accessdate">. Retrieved <span class="nowrap">10 November</span> 2017</span>.</cite></span>
</li>
<li id="cite_note-21"><span class="mw-cite-backlink"><b><a href="#cite_ref-21">^</a></b></span> <span class="reference-text"><cite id="CITEREFWall2004" class="citation web cs1"><a href="Larry_Wall" title="Larry Wall">Wall, Larry</a> (10 August 2004). <a rel="nofollow" class="external text" href="https://design.raku.org/S01.html">"Synopsis 1: Overview"</a>.</cite></span>
</li>
<li id="cite_note-22"><span class="mw-cite-backlink"><b><a href="#cite_ref-22">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://github.com/rakudo/rakudo/">"rakudo/rakudo - GitHub"</a>. Github.com<span class="reference-accessdate">. Retrieved <span class="nowrap">21 September</span> 2013</span>.</cite></span>
</li>
<li id="cite_note-23"><span class="mw-cite-backlink"><b><a href="#cite_ref-23">^</a></b></span> <span class="reference-text"><cite id="CITEREFMichaud,_Patrick2008" class="citation web cs1">Michaud, Patrick (16 January 2008). <a rel="nofollow" class="external text" href="https://web.archive.org/web/20120218080103/http://use.perl.org/~pmichaud/journal/35400">"The compiler formerly known as 'perl6'"</a>. Archived from <a rel="nofollow" class="external text" href="http://use.perl.org/~pmichaud/journal/35400">the original</a> on 18 February 2012.</cite></span>
</li>
<li id="cite_note-24"><span class="mw-cite-backlink"><b><a href="#cite_ref-24">^</a></b></span> <span class="reference-text"><cite id="CITEREFWorthington2013" class="citation web cs1">Worthington, Jonathan (31 May 2013). <a rel="nofollow" class="external text" href="http://6guts.wordpress.com/2013/05/31/moarvm-a-virtual-machine-for-nqp-and-rakudo/">"MoarVM: A virtual machine for NQP and Rakudo"</a>. <i>6guts</i><span class="reference-accessdate">. Retrieved <span class="nowrap">24 July</span> 2013</span>.</cite></span>
</li>
<li id="cite_note-25"><span class="mw-cite-backlink"><b><a href="#cite_ref-25">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://github.com/Raku/nqp">"NQP - Not Quite Perl at github"</a>. <i><a href="GitHub" title="GitHub">GitHub</a></i>. 29 May 2022<span class="reference-accessdate">. Retrieved <span class="nowrap">29 May</span> 2022</span>.</cite></span>
</li>
<li id="cite_note-26"><span class="mw-cite-backlink"><b><a href="#cite_ref-26">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://web.archive.org/web/20190207035658/https://perl6.org/compilers/features">"Feature comparison of Perl 6 compilers"</a>. Archived from <a rel="nofollow" class="external text" href="https://perl6.org/compilers/features">the original</a> on 7 February 2019.</cite></span>
</li>
<li id="cite_note-STD-27"><span class="mw-cite-backlink"><b><a href="#cite_ref-STD_27-0">^</a></b></span> <span class="reference-text"><cite id="CITEREFWall2007" class="citation web cs1"><a href="Larry_Wall" title="Larry Wall">Wall, Larry</a>; et&nbsp;al. (2007). <a rel="nofollow" class="external text" href="https://github.com/perl6/std/blob/master/STD.pm6">"Perl 6 STD"</a>. <i><a href="GitHub" title="GitHub">GitHub</a></i>.</cite></span>
</li>
<li id="cite_note-28"><span class="mw-cite-backlink"><b><a href="#cite_ref-28">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://web.archive.org/web/20070928200017/http://darcs.pugscode.org/v6/v6-KindaPerl6/docs/FAQ.pod">"mp6/kp6 FAQ"</a>. Perl 6 development team. 2006. Archived from <a rel="nofollow" class="external text" href="http://darcs.pugscode.org/v6/v6-KindaPerl6/docs/FAQ.pod">the original</a> on 28 September 2007<span class="reference-accessdate">. Retrieved <span class="nowrap">2 April</span> 2007</span>.</cite></span>
</li>
<li id="cite_note-29"><span class="mw-cite-backlink"><b><a href="#cite_ref-29">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://github.com/masak/yapsi/blob/master/README">"Yapsi README"</a>. <i><a href="GitHub" title="GitHub">GitHub</a></i>. 2011.</cite></span>
</li>
<li id="cite_note-nieczareadme-30"><span class="mw-cite-backlink"><b><a href="#cite_ref-nieczareadme_30-0">^</a></b></span> <span class="reference-text"><cite id="CITEREFO'Rear2011" class="citation web cs1">O'Rear, Stefan (29 November 2011). <a rel="nofollow" class="external text" href="https://github.com/sorear/niecza/blob/master/README.pod">"Niecza README.pod"</a>. <i><a href="GitHub" title="GitHub">GitHub</a></i><span class="reference-accessdate">. Retrieved <span class="nowrap">12 January</span> 2012</span>.</cite></span>
</li>
<li id="cite_note-31"><span class="mw-cite-backlink"><b><a href="#cite_ref-31">^</a></b></span> <span class="reference-text"><cite id="CITEREFWall2004" class="citation web cs1"><a href="Larry_Wall" title="Larry Wall">Wall, Larry</a> (2004). <a rel="nofollow" class="external text" href="https://design.raku.org/S11.html">"Synopsis 11: Modules"</a>.</cite></span>
</li>
<li id="cite_note-32"><span class="mw-cite-backlink"><b><a href="#cite_ref-32">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://modules.raku.org/">"Perl 6 Modules Directory"</a>. Modules.raku.org<span class="reference-accessdate">. Retrieved <span class="nowrap">17 May</span> 2020</span>.</cite></span>
</li>
<li id="cite_note-syn01-33"><span class="mw-cite-backlink"><b><a href="#cite_ref-syn01_33-0">^</a></b></span> <span class="reference-text"><cite id="CITEREFWall,_Larry2004" class="citation web cs1">Wall, Larry (10 August 2004). <a rel="nofollow" class="external text" href="https://design.raku.org/S01.html">"Synopsis 1: Overview"</a>.</cite></span>
</li>
<li id="cite_note-syn2-34"><span class="mw-cite-backlink">^ <a href="#cite_ref-syn2_34-0"><sup><i><b>a</b></i></sup></a> <a href="#cite_ref-syn2_34-1"><sup><i><b>b</b></i></sup></a></span> <span class="reference-text"><cite id="CITEREFWall,_Larry2009" class="citation web cs1">Wall, Larry (20 May 2009). <a rel="nofollow" class="external text" href="https://design.raku.org/S02.html">"Synopsis 2: Bits and Pieces"</a>.</cite></span>
</li>
<li id="cite_note-syn6-35"><span class="mw-cite-backlink">^ <a href="#cite_ref-syn6_35-0"><sup><i><b>a</b></i></sup></a> <a href="#cite_ref-syn6_35-1"><sup><i><b>b</b></i></sup></a> <a href="#cite_ref-syn6_35-2"><sup><i><b>c</b></i></sup></a></span> <span class="reference-text"><cite id="CITEREFWall,_Larry2003" class="citation web cs1">Wall, Larry (21 March 2003). <a rel="nofollow" class="external text" href="https://design.raku.org/S06.html">"Synopsis 6: Subroutines"</a>.</cite></span>
</li>
<li id="cite_note-syn04-36"><span class="mw-cite-backlink">^ <a href="#cite_ref-syn04_36-0"><sup><i><b>a</b></i></sup></a> <a href="#cite_ref-syn04_36-1"><sup><i><b>b</b></i></sup></a></span> <span class="reference-text"><cite id="CITEREFWall,_Larry2009" class="citation web cs1">Wall, Larry (20 May 2009). <a rel="nofollow" class="external text" href="https://design.raku.org/S04.html">"Synopsis 4: Blocks and Statements"</a>.</cite></span>
</li>
<li id="cite_note-37"><span class="mw-cite-backlink"><b><a href="#cite_ref-37">^</a></b></span> <span class="reference-text"><cite id="CITEREFWall,_Larry2006" class="citation web cs1">Wall, Larry (18 August 2006). <a rel="nofollow" class="external text" href="https://design.raku.org/S12.html">"Synopsis 12: Objects"</a>.</cite></span>
</li>
<li id="cite_note-38"><span class="mw-cite-backlink"><b><a href="#cite_ref-38">^</a></b></span> <span class="reference-text"><cite id="CITEREFThe_Software_Composition_Group2003" class="citation web cs1">The Software Composition Group (2003). <a rel="nofollow" class="external text" href="https://web.archive.org/web/20060811170712/http://www.iam.unibe.ch/~scg/Research/Traits/">"Traits"</a>. Archived from <a rel="nofollow" class="external text" href="http://www.iam.unibe.ch/~scg/Research/Traits/">the original</a> on 11 August 2006<span class="reference-accessdate">. Retrieved <span class="nowrap">22 September</span> 2006</span>.</cite></span>
</li>
<li id="cite_note-39"><span class="mw-cite-backlink"><b><a href="#cite_ref-39">^</a></b></span> <span class="reference-text"><cite id="CITEREFWorthington2009" class="citation web cs1">Worthington, Jonathan (2009). <a rel="nofollow" class="external text" href="https://perl6advent.wordpress.com/2009/12/18/day-18-roles/">"Day 18: Roles"</a>.</cite></span>
</li>
<li id="cite_note-40"><span class="mw-cite-backlink"><b><a href="#cite_ref-40">^</a></b></span> <span class="reference-text"><cite id="CITEREFchromatic2009" class="citation web cs1"><a href="Chromatic_(programmer)" title="Chromatic (programmer)">chromatic</a> (2009). <a rel="nofollow" class="external text" href="http://www.modernperlbooks.com/mt/2009/04/the-why-of-perl-roles.html">"The Why of Perl Roles"</a>.</cite></span>
</li>
<li id="cite_note-41"><span class="mw-cite-backlink"><b><a href="#cite_ref-41">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://docs.raku.org/language/objects#Automatic_role_punning">"Object orientation"</a>. <i>docs.raku.org</i><span class="reference-accessdate">. Retrieved <span class="nowrap">24 October</span> 2019</span>.</cite></span>
</li>
<li id="cite_note-42"><span class="mw-cite-backlink"><b><a href="#cite_ref-42">^</a></b></span> <span class="reference-text"><cite id="CITEREFParlante,_Nick2000" class="citation web cs1">Parlante, Nick (2000). <a rel="nofollow" class="external text" href="http://cslibrary.stanford.edu/108/EssentialPerl.html#re">"Essential Perl: String Processing with Regular Expressions"</a>.</cite></span>
</li>
<li id="cite_note-43"><span class="mw-cite-backlink"><b><a href="#cite_ref-43">^</a></b></span> <span class="reference-text"><cite id="CITEREFChristiansen,_Tom1996" class="citation web cs1">Christiansen, Tom (1996). <a rel="nofollow" class="external text" href="https://web.archive.org/web/20100331122815/http://www.perl.com/doc/FMTEYEWTK/regexps.html">"PERL5 Regular Expression Description"</a>. Archived from <a rel="nofollow" class="external text" href="http://www.perl.com/doc/FMTEYEWTK/regexps.html">the original</a> on 31 March 2010<span class="reference-accessdate">. Retrieved <span class="nowrap">25 March</span> 2010</span>. <q>Perl's regexps "aren't" -- that is, they aren't "regular" because backreferences per sed and grep are also supported, which renders the language no longer strictly regular</q></cite></span>
</li>
<li id="cite_note-44"><span class="mw-cite-backlink"><b><a href="#cite_ref-44">^</a></b></span> <span class="reference-text"><cite id="CITEREFWall,_Larry2009" class="citation web cs1">Wall, Larry (20 May 2009). <a rel="nofollow" class="external text" href="https://design.raku.org/S05.html">"Synopsis 5: Regexes and Rules"</a>.</cite></span>
</li>
<li id="cite_note-45"><span class="mw-cite-backlink"><b><a href="#cite_ref-45">^</a></b></span> <span class="reference-text"><cite id="CITEREFWall,_Larry2002" class="citation web cs1">Wall, Larry (4 June 2002). <a rel="nofollow" class="external text" href="https://web.archive.org/web/20210822004436/https://raku.org/archive/doc/design/apo/A05.html">"Apocalypse 5: Pattern Matching"</a>. Archived from <a rel="nofollow" class="external text" href="https://raku.org/archive/doc/design/apo/A05.html">the original</a> on 22 August 2021<span class="reference-accessdate">. Retrieved <span class="nowrap">16 May</span> 2020</span>.</cite></span>
</li>
<li id="cite_note-syn9-46"><span class="mw-cite-backlink">^ <a href="#cite_ref-syn9_46-0"><sup><i><b>a</b></i></sup></a> <a href="#cite_ref-syn9_46-1"><sup><i><b>b</b></i></sup></a></span> <span class="reference-text"><cite id="CITEREFWall,_Larry2004" class="citation web cs1">Wall, Larry (13 September 2004). <a rel="nofollow" class="external text" href="https://design.raku.org/S09.html">"Synopsis 9: Data Structures"</a>.</cite></span>
</li>
<li id="cite_note-47"><span class="mw-cite-backlink"><b><a href="#cite_ref-47">^</a></b></span> <span class="reference-text"><cite id="CITEREFLamkins,_David_B.2004" class="citation book cs1">Lamkins, David B. (8 December 2004). <a rel="nofollow" class="external text" href="https://web.archive.org/web/20060912113327/http://www.psg.com/~dlamkins/sl/chapter20.html"><i>Successful Lisp: How to Understand and Use Common Lisp</i></a>. bookfix.com. Archived from <a rel="nofollow" class="external text" href="http://psg.com/~dlamkins/sl/chapter20.html">the original</a> on 12 September 2006<span class="reference-accessdate">. Retrieved <span class="nowrap">13 September</span> 2006</span>.</cite></span>
</li>
<li id="cite_note-macros-48"><span class="mw-cite-backlink"><b><a href="#cite_ref-macros_48-0">^</a></b></span> <span class="reference-text"><cite class="citation web cs1"><a rel="nofollow" class="external text" href="https://github.com/Raku/old-design-docs">"Raku/old-design-docs"</a>. 10 September 2024 – via GitHub.</cite></span>
</li>
</ol></div></div>
<div class="mw-heading mw-heading2"><h2 id="External_links">External links</h2></div>
<style data-mw-deduplicate="TemplateStyles:r1290876196">
/* start https://en.wikipedia.org/ */


.mw-parser-output .side-box{margin:4px 0;box-sizing:border-box;border:1px solid #aaa;font-size:88%;line-height:1.25em;background-color:var(--background-color-interactive-subtle,#f8f9fa);display:flow-root}.mw-parser-output .infobox .side-box{font-size:100%}.mw-parser-output .side-box-abovebelow,.mw-parser-output .side-box-text{padding:0.25em 0.9em}.mw-parser-output .side-box-image{padding:2px 0 2px 0.9em;text-align:center}.mw-parser-output .side-box-imageright{padding:2px 0.9em 2px 0;text-align:center}@media(min-width:500px){.mw-parser-output .side-box-flex{display:flex;align-items:center}.mw-parser-output .side-box-text{flex:1;min-width:0}}@media(min-width:720px){.mw-parser-output .side-box{width:238px}.mw-parser-output .side-box-right{clear:right;float:right;margin-left:1em}.mw-parser-output .side-box-left{margin-right:1em}}


/* end https://en.wikipedia.org/ */
</style><style data-mw-deduplicate="TemplateStyles:r1237033735">
/* start https://en.wikipedia.org/ */


@media print{body.ns-0 .mw-parser-output .sistersitebox{display:none!important}}@media screen{html.skin-theme-clientpref-night .mw-parser-output .sistersitebox img[src*="Wiktionary-logo-en-v2.svg"]{background-color:white}}@media screen and (prefers-color-scheme:dark){html.skin-theme-clientpref-os .mw-parser-output .sistersitebox img[src*="Wiktionary-logo-en-v2.svg"]{background-color:white}}


/* end https://en.wikipedia.org/ */
</style><div class="side-box side-box-right sistersitebox"><style data-mw-deduplicate="TemplateStyles:r1126788409">
/* start https://en.wikipedia.org/ */


.mw-parser-output .plainlist ol,.mw-parser-output .plainlist ul{line-height:inherit;list-style:none;margin:0;padding:0}.mw-parser-output .plainlist ol li,.mw-parser-output .plainlist ul li{margin-bottom:0}


/* end https://en.wikipedia.org/ */
</style>
<div class="side-box-flex">
<div class="side-box-image"><span class="noviewer" typeof="mw:File"></span></div>
<div class="side-box-text plainlist">Wikibooks has a book on the topic of: <i><b><a href="https://en.wikibooks.org/wiki/Perl_6_Programming" class="extiw external" title="wikibooks:Perl 6 Programming">Perl 6 Programming</a></b></i></div></div>
</div>
<ul><li><span class="official-website"><span class="url"><a rel="nofollow" class="external text" href="https://raku.org/">Official website</a></span></span> </li></ul>
<div class="navbox-styles"><style data-mw-deduplicate="TemplateStyles:r1129693374">
/* start https://en.wikipedia.org/ */


.mw-parser-output .hlist dl,.mw-parser-output .hlist ol,.mw-parser-output .hlist ul{margin:0;padding:0}.mw-parser-output .hlist dd,.mw-parser-output .hlist dt,.mw-parser-output .hlist li{margin:0;display:inline}.mw-parser-output .hlist.inline,.mw-parser-output .hlist.inline dl,.mw-parser-output .hlist.inline ol,.mw-parser-output .hlist.inline ul,.mw-parser-output .hlist dl dl,.mw-parser-output .hlist dl ol,.mw-parser-output .hlist dl ul,.mw-parser-output .hlist ol dl,.mw-parser-output .hlist ol ol,.mw-parser-output .hlist ol ul,.mw-parser-output .hlist ul dl,.mw-parser-output .hlist ul ol,.mw-parser-output .hlist ul ul{display:inline}.mw-parser-output .hlist .mw-empty-li{display:none}.mw-parser-output .hlist dt::after{content:": "}.mw-parser-output .hlist dd::after,.mw-parser-output .hlist li::after{content:" · ";font-weight:bold}.mw-parser-output .hlist dd:last-child::after,.mw-parser-output .hlist dt:last-child::after,.mw-parser-output .hlist li:last-child::after{content:none}.mw-parser-output .hlist dd dd:first-child::before,.mw-parser-output .hlist dd dt:first-child::before,.mw-parser-output .hlist dd li:first-child::before,.mw-parser-output .hlist dt dd:first-child::before,.mw-parser-output .hlist dt dt:first-child::before,.mw-parser-output .hlist dt li:first-child::before,.mw-parser-output .hlist li dd:first-child::before,.mw-parser-output .hlist li dt:first-child::before,.mw-parser-output .hlist li li:first-child::before{content:" (";font-weight:normal}.mw-parser-output .hlist dd dd:last-child::after,.mw-parser-output .hlist dd dt:last-child::after,.mw-parser-output .hlist dd li:last-child::after,.mw-parser-output .hlist dt dd:last-child::after,.mw-parser-output .hlist dt dt:last-child::after,.mw-parser-output .hlist dt li:last-child::after,.mw-parser-output .hlist li dd:last-child::after,.mw-parser-output .hlist li dt:last-child::after,.mw-parser-output .hlist li li:last-child::after{content:")";font-weight:normal}.mw-parser-output .hlist ol{counter-reset:listitem}.mw-parser-output .hlist ol>li{counter-increment:listitem}.mw-parser-output .hlist ol>li::before{content:" "counter(listitem)"\a0 "}.mw-parser-output .hlist dd ol>li:first-child::before,.mw-parser-output .hlist dt ol>li:first-child::before,.mw-parser-output .hlist li ol>li:first-child::before{content:" ("counter(listitem)"\a0 "}


/* end https://en.wikipedia.org/ */
</style><style data-mw-deduplicate="TemplateStyles:r1236075235">
/* start https://en.wikipedia.org/ */


.mw-parser-output .navbox{box-sizing:border-box;border:1px solid #a2a9b1;width:100%;clear:both;font-size:88%;text-align:center;padding:1px;margin:1em auto 0}.mw-parser-output .navbox .navbox{margin-top:0}.mw-parser-output .navbox+.navbox,.mw-parser-output .navbox+.navbox-styles+.navbox{margin-top:-1px}.mw-parser-output .navbox-inner,.mw-parser-output .navbox-subgroup{width:100%}.mw-parser-output .navbox-group,.mw-parser-output .navbox-title,.mw-parser-output .navbox-abovebelow{padding:0.25em 1em;line-height:1.5em;text-align:center}.mw-parser-output .navbox-group{white-space:nowrap;text-align:right}.mw-parser-output .navbox,.mw-parser-output .navbox-subgroup{background-color:#fdfdfd}.mw-parser-output .navbox-list{line-height:1.5em;border-color:#fdfdfd}.mw-parser-output .navbox-list-with-group{text-align:left;border-left-width:2px;border-left-style:solid}.mw-parser-output tr+tr>.navbox-abovebelow,.mw-parser-output tr+tr>.navbox-group,.mw-parser-output tr+tr>.navbox-image,.mw-parser-output tr+tr>.navbox-list{border-top:2px solid #fdfdfd}.mw-parser-output .navbox-title{background-color:#ccf}.mw-parser-output .navbox-abovebelow,.mw-parser-output .navbox-group,.mw-parser-output .navbox-subgroup .navbox-title{background-color:#ddf}.mw-parser-output .navbox-subgroup .navbox-group,.mw-parser-output .navbox-subgroup .navbox-abovebelow{background-color:#e6e6ff}.mw-parser-output .navbox-even{background-color:#f7f7f7}.mw-parser-output .navbox-odd{background-color:transparent}.mw-parser-output .navbox .hlist td dl,.mw-parser-output .navbox .hlist td ol,.mw-parser-output .navbox .hlist td ul,.mw-parser-output .navbox td.hlist dl,.mw-parser-output .navbox td.hlist ol,.mw-parser-output .navbox td.hlist ul{padding:0.125em 0}.mw-parser-output .navbox .navbar{display:block;font-size:100%}.mw-parser-output .navbox-title .navbar{float:left;text-align:left;margin-right:0.5em}body.skin--responsive .mw-parser-output .navbox-image img{max-width:none!important}@media print{body.ns-0 .mw-parser-output .navbox{display:none!important}}


/* end https://en.wikipedia.org/ */
</style></div><div role="navigation" class="navbox" aria-labelledby="Perl142" style="padding:3px"><table class="nowraplinks hlist mw-collapsible mw-collapsed navbox-inner" style="border-spacing:0;background:transparent;color:inherit"><tbody><tr><th scope="col" class="navbox-title" colspan="2"><style data-mw-deduplicate="TemplateStyles:r1239400231">
/* start https://en.wikipedia.org/ */


.mw-parser-output .navbar{display:inline;font-size:88%;font-weight:normal}.mw-parser-output .navbar-collapse{float:left;text-align:left}.mw-parser-output .navbar-boxtext{word-spacing:0}.mw-parser-output .navbar ul{display:inline-block;white-space:nowrap;line-height:inherit}.mw-parser-output .navbar-brackets::before{margin-right:-0.125em;content:"[ "}.mw-parser-output .navbar-brackets::after{margin-left:-0.125em;content:" ]"}.mw-parser-output .navbar li{word-spacing:-0.125em}.mw-parser-output .navbar a>span,.mw-parser-output .navbar a>abbr{text-decoration:inherit}.mw-parser-output .navbar-mini abbr{font-variant:small-caps;border-bottom:none;text-decoration:none;cursor:inherit}.mw-parser-output .navbar-ct-full{font-size:114%;margin:0 7em}.mw-parser-output .navbar-ct-mini{font-size:114%;margin:0 4em}html.skin-theme-clientpref-night .mw-parser-output .navbar li a abbr{color:var(--color-base)!important}@media(prefers-color-scheme:dark){html.skin-theme-clientpref-os .mw-parser-output .navbar li a abbr{color:var(--color-base)!important}}@media print{.mw-parser-output .navbar{display:none!important}}


/* end https://en.wikipedia.org/ */
</style><div id="Perl142" style="font-size:114%;margin:0 4em"><a href="Perl" title="Perl">Perl</a></div></th></tr><tr><th scope="row" class="navbox-group" style="width:1%">Things</th><td class="navbox-list-with-group navbox-list navbox-odd" style="width:100%;padding:0"><div style="padding:0 0.25em">
<ul><li><a href="CPAN" title="CPAN">CPAN</a></li>
<li><a href="Perl_Foundation" title="Perl Foundation">Perl Foundation</a>
<ul><li><a href="Perl_Mongers" title="Perl Mongers">Perl Mongers</a></li>
<li><a href="PerlMonks" title="PerlMonks">PerlMonks</a></li>
<li><a href="CPAN" title="CPAN">archives</a></li></ul></li>
<li><a href="Perl_module" title="Perl module">module</a></li>
<li><a href="Perl_virtual_machine" title="Perl virtual machine">Perl VM</a></li>
<li><a href="Yet_Another_Perl_Conference" title="Yet Another Perl Conference">YAPC</a></li></ul>
</div></td></tr><tr><th scope="row" class="navbox-group" style="width:1%"><a href="Software_framework" title="Software framework">Frameworks</a></th><td class="navbox-list-with-group navbox-list navbox-even" style="width:100%;padding:0"><div style="padding:0 0.25em">
<ul><li><a href="BioPerl" title="BioPerl">BioPerl</a></li>
<li><a href="Catalyst_(software)" title="Catalyst (software)">Catalyst</a></li>
<li><a href="Dancer_(software)" title="Dancer (software)">Dancer</a></li>
<li><a href="Perl_DBI" title="Perl DBI">DBI</a></li>
<li><a href="DBIx%3A%3AClass" title="DBIx::Class">DBIx::Class</a></li>
<li><a href="Library_for_WWW_in_Perl" title="Library for WWW in Perl">LWP</a></li>
<li><a href="Mojolicious" title="Mojolicious">Mojolicious</a></li>
<li><a href="Moose_(Perl)" title="Moose (Perl)">Moose</a></li>
<li><a href="Plack_(software)" title="Plack (software)">Plack</a></li>
<li><a href="PSGI" class="mw-redirect" title="PSGI">PSGI</a></li>
<li><a href="Template_Toolkit" title="Template Toolkit">Template Toolkit</a></li></ul>
</div></td></tr><tr><th scope="row" class="navbox-group" style="width:1%">Software</th><td class="navbox-list-with-group navbox-list navbox-odd" style="width:100%;padding:0"><div style="padding:0 0.25em">
<ul><li><a href="Amavis" title="Amavis">Amavis</a></li>
<li><a href="Argus_(monitoring_software)" title="Argus (monitoring software)">Argus</a></li>
<li><a href="Anti-Spam_SMTP_Proxy" title="Anti-Spam SMTP Proxy">@SSP</a></li>
<li><a href="AWStats" title="AWStats">AWStats</a></li>
<li><a href="BackupPC" title="BackupPC">BackupPC</a></li>
<li><a href="Bricolage_(software)" title="Bricolage (software)">Bricolage</a></li>
<li><a href="Bugzilla" title="Bugzilla">Bugzilla</a></li>
<li><a href="Dada_Mail" title="Dada Mail">Dada Mail</a></li>
<li><a href="Ikiwiki" title="Ikiwiki">ikiwiki</a></li>
<li><a href="Make_(software)#Modern_versions" title="Make (software)">Makepp</a></li>
<li><a href="Movable_Type" title="Movable Type">Movable Type</a></li>
<li><a href="Munin_(software)" title="Munin (software)">Munin</a></li>
<li><a href="OTRS" title="OTRS">OTRS</a></li>
<li><a href="Request_Tracker" title="Request Tracker">Request Tracker</a></li>
<li><a href="SpamAssassin" class="mw-redirect" title="SpamAssassin">SpamAssassin</a></li>
<li><a href="TWiki" title="TWiki">TWiki</a>/<a href="Foswiki" title="Foswiki">Foswiki</a></li>
<li><a href="W3Perl" title="W3Perl">W3Perl</a></li>
<li><a href="Webmin" title="Webmin">Webmin</a></li></ul>
</div></td></tr><tr><th scope="row" class="navbox-group" style="width:1%">Related</th><td class="navbox-list-with-group navbox-list navbox-even" style="width:100%;padding:0"><div style="padding:0 0.25em">
<ul><li><a href="Parrot_virtual_machine" title="Parrot virtual machine">Parrot</a></li>
<li>
<ul><li><a href="Rakudo" title="Rakudo">Rakudo</a></li>
<li><a href="Raku_rules" title="Raku rules">rules</a></li>
<li><a href="MoarVM" title="MoarVM">MoarVM</a></li></ul></li></ul>
</div></td></tr><tr><th scope="row" class="navbox-group" style="width:1%">Books</th><td class="navbox-list-with-group navbox-list navbox-odd" style="width:100%;padding:0"><div style="padding:0 0.25em">
<ul><li><a href="Programming_Perl" title="Programming Perl">Programming Perl</a></li>
<li><a href="Learning_Perl" title="Learning Perl">Learning Perl</a></li>
<li><a href="Intermediate_Perl" title="Intermediate Perl">Intermediate Perl</a></li>
<li><a href="Perl_Best_Practices" class="mw-redirect" title="Perl Best Practices">Perl Best Practices</a></li></ul>
</div></td></tr><tr><th scope="row" class="navbox-group" style="width:1%">People</th><td class="navbox-list-with-group navbox-list navbox-even" style="width:100%;padding:0"><div style="padding:0 0.25em">
<ul><li><a href="Larry_Wall" title="Larry Wall">Larry Wall</a></li>
<li><a href="Randal_L._Schwartz" title="Randal L. Schwartz">Randal L. Schwartz</a></li>
<li><a href="Damian_Conway" title="Damian Conway">Damian Conway</a></li>
<li><a href="Allison_Randal" title="Allison Randal">Allison Randal</a></li>
<li><a href="Audrey_Tang" title="Audrey Tang">Audrey Tang</a></li>
<li><a href="Sean_M._Burke" title="Sean M. Burke">Sean M. Burke</a></li>
<li><a href="Chromatic_(programmer)" title="Chromatic (programmer)">chromatic</a></li>
<li><a href="Brian_d_foy" title="Brian d foy">brian d foy</a></li>
<li><a href="Jesse_Vincent" title="Jesse Vincent">Jesse Vincent</a></li></ul>
</div></td></tr><tr><td class="navbox-abovebelow" colspan="2"><div>
<ul><li><b><a href="Outline_of_Perl" title="Outline of Perl">Outline</a></b></li>
<li><b>Category</b></li></ul>
</div></td></tr></tbody></table></div></div><!--htdig_noindex--><div><div class="zim-footer">
This article is issued from <a class="external text" title="Last edited on 2025-07-30" href="https://en.wikipedia.org/wiki/?title=Raku_(programming_language)&amp;oldid=1303338454">Wikipedia</a>. The text is available under <a class="external text" href="https://creativecommons.org/licenses/by-sa/4.0/deed.en">Creative Commons Attribution-Share Alike 4.0</a> unless otherwise noted. Additional terms may apply for the media files.
</div>
</div><!--/htdig_noindex--></div>
</div>
</main>
</div>
</div>
</div>

</body></html>